// dlg.txt

begintalkscript;

variables;

short i;



begintalknode 4;
	state = -1;
	nextstate = -1;
	condition = 1;
	question = "special";
	text1 = "The lizards chained at this pool are weak emaciated creatures, lacking the strength even to try to bite or maim you. Soon, their only value will be as a stringy, unpleasant meal.";

begintalknode 5;
	state = -1;
	nextstate = -1;
	condition = 1;
	question = "special";
	text1 = "The refugees get very quiet whenever you get near, but you manage to pick up a few snippets of their conversation:";
	text2 = "_Stay away from Silvar. There's no law there now. No law but that the strong get what they want._";
	text3 = "_Shot a lizard last week. Two whole pounds! Kept my family going for days. But hunting's getting harder and harder._";
	text4 = "_What does that soldier want? Their lot is too busy hoarding the food to protect us from the bandits._";
	text5 = "_I saw a bone moving the other day. It was sitting on the ground, and it started to slide around on its own. It's the curse, I tell you!_";
	text6 = "_Mertis is done for. You'll never see anyone farming there again. They'll all be dead or up the portal, if they ever repair it._";
	text7 = "_Don't camp too far into the Eastern Gallery. I heard a band of a dozen tried it. A chitrach swarm got them. Barely had time to draw steel, they did._";
	text8 = "_I've heard strange things have been happening around old Avernum. Even people disappearing. Stay away from there!_";
	code =
		clear_strings();
		as(1);
		as(2 + get_ran(1,0,6));
	break;

begintalknode 6;
	state = -1;
	nextstate = -1;
	condition = 1;
	question = "special";
	text1 = "There are several grimy brigands sitting around this campfire. They ignore you.";
	
begintalknode 7;
	state = -1;
	nextstate = -1;
	condition = 1;
	question = "special";
	text1 = "The sign says:";
	text2 = "  Mertis - South";
	text3 = "  Eastern Gallery, Silvar - North";
	text4 = "  Tower Colony, Great Portal - South";

//

begintalknode 10;
	state = -1;
	nextstate = 10;
	condition = 1;
	question = "Name";
	text1 = "There is a fletcher sitting off from the main group of refugees. She sits by her blanket, working on a cavewood bow. Her own bow sits nearby, ready for use if someone threatens her.";
	text2 = "She looks up at you and smiles. Weeks on the road have not completely stripped away her manners. _Good day to you. I am Deirdre. I am a fletcher by trade. Perhaps I can sell something to aid in your day's hunt?_";
	text5 = "Deirdre carefully bends a length of cavewood and puts on the bowstring. She tests the bow, shakes her head, and removes the string.";
	text6 = "_It seems like even the cavewood is worse these days._";
	action = INTRO;

begintalknode 11;
	state = 10;
	nextstate = 11;
	condition = 1;
	question = "You are still making bows while on the road?";
	text1 = "_Oh, yes. There is huge demand. Few of the refugees have anything left to pay me, so I sell them cavewood bows very cheaply. Then they can defend themselves, and maybe even get a little food._";

begintalknode 12;
	state = 11;
	nextstate = -1;
	condition = 1;
	question = "Defend themselves against what?";
	text1 = "_Brigands and bullies. The bows aren't much, I admit, but even the threat of a wound is usually able to scare off a lone thug or a skribbane eater._";

begintalknode 13;
	state = 11;
	nextstate = -1;
	condition = 1;
	question = "What do they hunt for?";
	text1 = "She looks up at the ceiling, fifty feet above you. You note an unusual absence of bats. _They hunt lizards. Bats. Even fish. But those sources of food are becoming rarer and rarer, hunted to nothingness._";

begintalknode 14;
	state = 10;
	nextstate = 12;
	condition = 1;
	question = "Can you tell me about the area?";
	text1 = "She smiles, trying to keep a good attitude. _Always glad to help. I've been up and down this road for weeks. Mertis is to the south, though I imagine you've already been there. The tunnels to the east are haunted. Stay away from there._";
	text2 = "_And the Eastern Gallery is to the north. It's not as bad a place for a refugee, these days._";

begintalknode 15;
	state = 12;
	nextstate = -1;
	condition = 1;
	question = "What do you know about the haunted tunnels?";
	text1 = "_Well, I'm originally from Formello. Everyone in the east and north has heard of the undead tunnels, where the dead come back to life. The people of Mertis have long burned their dead, so that the curse couldn't claim them._";
	text2 = "_Not even the most desperate refugee goes back there._";

begintalknode 16;
	state = 12;
	nextstate = 13;
	condition = 1;
	question = "Why is the Eastern Gallery better?";
	text1 = "_There is still room to camp and game to hunt, and the brigands tend to stay away from the front._";
	text2 = "_Of course, if the Slith Horde breaks through, you have to be ready to run. But, as long as you watch out for Silvar and the chitrachs, you should be fine._";

begintalknode 17;
	state = 13;
	nextstate = -1;
	condition = 1;
	question = "What is wrong with Silvar?";
	text1 = "_What few thugs are left in the gallery are there. The mayor has lost control. It's a savage place now, one to beware. Of course, you're a soldier, so you should be fine._";

begintalknode 18;
	state = 13;
	nextstate = -1;
	condition = 1;
	question = "What are chitrachs?";
	text1 = "_The plague of the caves. Huge bugs. Nasty and meat eating, and they swarm. The soldiers aren't free to keep them under control anymore. If you head too far to the west in the gallery, you'll find them soon enough._";

begintalknode 19;
	state = 10;
	nextstate = -1;
	condition = 1;
	question = "Can I see your wares?";
	text1 = "You conclude your business.";	
	code = 
		begin_shop_mode("Deirdre the Fletcher",
		  "Deirdre has a few quality weapons left. She's been saving them for someone with actual money.",
		  53,4,0);	
	break;

	
begintalknode 20;
	state = 10;
	nextstate = -1;
	condition = 1;
	question = "That is all I need.";
	text1 = "_Then safe travels to you. I'll probably camp here for a few more weeks, in case you need something else._";
	action = END_TALK;
	
//

begintalknode 30;
	state = -1;
	nextstate = 30;
	condition = 1;
	question = "Name";
	text1 = "As you walk down the road north of Mertis, a man runs toward you. He looks filthy, bedraggled, and terrified. His leather jerkin has a long tear running down the front. An old broadsword hangs from his belt.";
	text2 = "_Soldiers,_ he pants. _At last ... Please ... I am Weylin. We need help. Brigands. Attacking. Please follow me. Help us._";


begintalknode 31;
	state = 30;
	nextstate = -1;
	condition = 1;
	question = "You want me to follow you?";
	text1 = "_Yes ... Please. We're holding them off, but there's little time. We need help!_";

begintalknode 32;
	state = 30;
	nextstate = -1;
	condition = 1;
	question = "What is wrong?";
	text1 = "He points the north and gasps, _Camped. Up there. Several of us. Brigands ... Attacked us. Fought them off. Killed one. They're besieging us. Need help, please._";

begintalknode 33;
	state = 30;
	nextstate = -1;
	condition = 1;
	question = "Where do you want me to go?";
	text1 = "_Our camp ... Off the road. Thought we'd be safe back there. We weren't. Don't have long._";

begintalknode 34;
	state = 30;
	nextstate = -1;
	condition = 1;
	question = "All right. Lead on.";
	text1 = "He nods and takes several deep breaths. _Thank you ... Thank you. Please hurry. Follow me._ He runs off toward the narrow tunnels to the north of the main road.";
	action = END_TALK;

begintalknode 35;
	state = 30;
	nextstate = -1;
	condition = 1;
	question = "Sorry. I'm too busy to help you.";
	text1 = "He looks stunned. He takes several deep breaths and says, _What? You won't ... Won't help us? You're a soldier ... That's what you ... You have to! Please! Please follow! I beg you ... We don't have long!_";
	text2 = "He turns and runs off toward the narrow tunnels to the north of the main road.";
	action = END_TALK;

begintalknode 40;
	state = -1;
	nextstate = -1;
	condition = 1;
	question = "";
	text1 = "You catch up with Weylin and the band of refugees he described. You find, however, that they don't look like pitiful refugees at all. They're armed people, dirty and vicious looking, accompanied by a large slithzerikai.";
	text2 = "You look around for their attackers. None are to be seen. Weylin turns to look at the slith. The slith nods. Weylin gives you a nasty smile.";
	text3 = "_You are the one. Kill them._ The thugs rise and attack.";
	code =
		set_attitude(30038,10);
		set_act_at_dist(30038,1);
		alert_char(30038);
		sf(124,4,3);
	break;
	
begintalknode 41;
	state = -1;
	nextstate = -1;
	condition = 1;
	question = "";
	text1 = "The treacherous Weylin collapses to the ground. He looks up at you and gasps. _We were told ... Told you would be easy. Would be ... weak. Shouldn't have ... I'm sorry._ And then he dies.";

begintalknode 42;
	state = -1;
	nextstate = -1;
	condition = 1;
	question = "";
	text1 = "The jar contains a loaf of moldy bread and a scroll. You discard the former and read the latter.";
	text2 = "It is a letter. It begins with a detailed description of you, followed by this message:";
	text3 = "_A constant irritation. To be slain. The Shadow will spare and reward those who do the will of the Horde. Even those not of our kind._";
	text4 = "The jar is empty.";
	code =
		clear_strings();
		if (gf(124,4) > 0) {
			as(1); as(2); as(3);
			}
			else as(4);
	break;
	
//

begintalknode 50;
	state = -1;
	nextstate = 50;
	condition = 1;
	question = "Name";
	text1 = ".";
	text2 = "";
	text5 = ".";
	action = INTRO;

begintalknode 51;
	state = 50;
	nextstate = -1;
	condition = 1;
	question = "";
	text1 = ".";
	text2 = "";

	
begintalknode 52;
	state = 50;
	nextstate = -1;
	condition = 1;
	question = "";
	text1 = ".";
	text2 = "";
	
begintalknode 53;
	state = 50;
	nextstate = -1;
	condition = 1;
	question = "";
	text1 = ".";
	text2 = "";
	
begintalknode 54;
	state = 50;
	nextstate = -1;
	condition = 1;
	question = "";
	text1 = ".";
	text2 = "";
	
begintalknode 55;
	state = 50;
	nextstate = -1;
	condition = 1;
	question = "";
	text1 = ".";
	text2 = "";
	
begintalknode 56;
	state = 50;
	nextstate = -1;
	condition = 1;
	question = "";
	text1 = ".";
	text2 = "";
	
begintalknode 57;
	state = 50;
	nextstate = -1;
	condition = 1;
	question = "";
	text1 = ".";
	text2 = "";
	
begintalknode 58;
	state = 50;
	nextstate = -1;
	condition = 1;
	question = "";
	text1 = ".";
	text2 = "";

begintalknode 59;
	state = 50;
	nextstate = -1;
	condition = 1;
	question = "";
	text1 = ".";
	text2 = "";

begintalknode 60;
	state = 50;
	nextstate = -1;
	condition = 1;
	question = "";
	text1 = ".";
	text2 = "";

begintalknode 61;
	state = 50;
	nextstate = -1;
	condition = 1;
	question = "";
	text1 = ".";
	text2 = "";

begintalknode 62;
	state = 50;
	nextstate = -1;
	condition = 1;
	question = "";
	text1 = ".";
	text2 = "";

begintalknode 63;
	state = 50;
	nextstate = -1;
	condition = 1;
	question = "";
	text1 = ".";
	text2 = "";

begintalknode 64;
	state = 50;
	nextstate = -1;
	condition = 1;
	question = "";
	text1 = ".";
	text2 = "";

////

begintalknode 299;
	state = -1;
	nextstate = -1;
	condition = 1;
	question = "";
	text1 = ".";
	text2 = "";
		