// TOWN DIALOGUE SCRIPT
//    Town 3: Marralis

// This is the dialogue for this town.
// You can use states numbered from 1 to 99.

begintalkscript;

variables;

int i,j,k,r1,choice;

begintalknode 1;
	state = -1;
	personality = 0;
	nextstate = -1;
	condition = 1;
	question = "Watchman";
	text1 = "The guard absolutely refuses to talk to you. He'll let nothing distract him from his duty.";
	action = END_TALK;
	
begintalknode 2;
	state = -1;
	personality = 4;
	nextstate = 1;
	condition = 1;
	question = "Lady Keria";
	text1 = "Lady Keria has almost collapsed; she is panting from exhaustion, and her wounds are severe. _Enough!_ she cries. _I'll tell you anything you want, I surrender!_";
	text2 = "Typical noble mentality. They think they can just declare something, and it'll be done; they think they can surrender; they think matters of life and death can be bent to their will.";
	text3 = "But she did offer to explain herself. That could be good, considering she has left quite a few questions unanswered.";
begintalknode 3;
	state = 1;
	personality = 4;
	nextstate = 1;
	condition = 1;
	question = "Why did you tell the Hunan to attack Megiddo? Why did you do all of this?";
	text1 = "_The Hunan were a distraction!_ Keria wails. _I was persuaded to assassinate the King. Not that I needed much convincing._ Lady Keria's eyes flash. _He shouldn't have interfered with the Prince and I..._";
	text2 = "_I thought that the best distraction would be if the Hunan were attacking Megiddo Tower. So I led their forces through the forest, to make it possible. I told them to attack Megiddo._ Lady Keria coughs, and there is blood.";
	text3 = "_I knew they wouldn't succeed,_ she whispers. _They're dumb animals; they would have been no match for the Megiddo army. But still, they would provide me with the distraction I needed. I had planned to poison the King while all eyes were on the Hunan..._";
	text4 = "_But I cannot... I cannot reveal who asked me to kill the King. It would bring destruction upon us all._";
	code = 
		set_flag(5,15,250);
		set_flag(5,16,250);
	break;
begintalknode 4;
	state = 1;
	personality = 4;
	nextstate = 1;
	condition = 1;
	question = "How did you get your powers?";
	text1 = "Keria shakes her head. _I have a... benefactor. Truth be told, I don't even understand how he granted me these powers, over the land and nature. But if I should reveal him... everything I know will be destroyed,_ she whispers.";
	text2 = "_I will carry that secret to my death... which may be soon,_ she says weakly. Although she was always cruel and arrogant, once Lady Keria is confronted with death, she's quite soft and easy to break.";
	code = 
		set_flag(5,15,250);
		set_flag(5,17,250);
	break;
begintalknode 5;
	state = 1;
	personality = 4;
	nextstate = 1;
	condition = 1;
	question = "Where is the King? How did you cause that earthquake?";
	text1 = "This question actually makes Lady Keria pause. _The King? Is he not in his chambers?_ And then a realization seems to dawn upon her; she covers her mouth and gasps. But weakly, as she's quite close to death.";
	text2 = "_I see..._ she murmurs. _Well... I had nothing to do with the King's disappearance, nor the earthquake. I intended to murder his majesty, true, but someone else evidently beat me to it._";
	text3 = "_If it makes you feel better, you can think I killed the King. Certainly I wanted the man dead; he was interfering in my plans, meddling with my dear Prince..._ She actually wipes away a tear.";
	code = 
		set_flag(5,18,250);
	break;
begintalknode 6;
	state = 1;
	personality = 4;
	nextstate = 1;
	condition = get_flag(0,13) > 0;
	question = "Did you kill the Megiddo custodian?";
	text1 = "Keria stares at you in amazement. _Yes. Yes I did. How did you know that?..._";
	text2 = "She smiles weakly. _I suppose since I shall soon die, it makes no difference... I paid him to build a secret addition into the back of my apartment in the northwest part of the tower, and when he finished, I killed him._";
	text3 = "_I used that room to hide the King's poison... I couldn't trust him to be quiet, especially if I were to actually kill the King. I had to kill him first... _";
	code = 
		set_flag(5,19,250);
	break;
begintalknode 7;
	state = 1;
	personality = 4;
	nextstate = 1;
	condition = get_flag(5,15) == 250;
	question = "Tell us who you're working for.";
	text1 = "Lady Keria shakes her head, but quickly stops; she is in too poor a condition. _I refuse. Kill me if you wish; I do not fear death so much as I fear the consequences._";
	text2 = "She refuses to speak any more about it.";
begintalknode 8;
	state = 1;
	personality = 4;
	nextstate = 1;
	condition = 1;
	question = "Time for you to die. (Kill Lady Keria)";
	text1 = "Lady Keria watches with apprehension as you come closer. She steels herself for the finishing blow. Then suddenly she says, _Wait! Tell the Prince... I'm sorry. And General Seth... Tell General Seth that I hate him._";
	text2 = "She closes her eyes slowly. _Now, end it._ You oblige.";
	code = 
		toggle_quest(6,0);
		toggle_quest(8,1);
		end();
	break;
begintalknode 9;
	state = 1;
	personality = 4;
	nextstate = 1;
	condition = 1;
	question = "I'll leave you here. (Walk away)";
	text1 = "Keria sniffs piteously. _I suppose I deserve that cruelty. Shall I wait here in agony until I rot away?_";
	text2 = "You begin walking away. Lady Keria continues speaking, almost to herself. _It is strange to think that I gave life to plants, and now my life flows back into the earth..._";
	text3 = "_I suppose, in the end, a King and a coward both are dust... I aspired to be so much... more..._ She slowly exhales; she doesn't breathe back in.";
	code = 
		toggle_quest(6,0);
		end();
	break;
	
begintalknode 10;
	state = -1;
	personality = 5;
	nextstate = 2;
	condition = 1;
	question = "Lord Kato";
	text1 = "This is Lord Kato, the owner of this estate; this puts him at the head of one of the most successful enterprises that Megiddo has ever seen.";
	text2 = "He takes one glance at you, and goes back to his business. _Whoever you are, whatever you want, I think you're in the wrong place; I know what my customers look like, and you are not one of them._";
begintalknode 11;
	state = 2;
	personality = 5;
	nextstate = 2;
	condition = get_flag(0,8) < 250;
	question = "I'm here to kill your daughter.";
	text1 = "Lord Kato takes this comment in stride. _Well, then, you must be lost; my daughter is in the Tower with her Prince._";
	text2 = "He points to the southwest. _You can find Keria there; the door is also that way. On your way out, make sure a guard beats you for your impudence._ It seems like he feels that's the end of the conversation.";
	action = END_TALK;
begintalknode 12;
	state = 2;
	personality = 5;
	nextstate = 2;
	condition = get_flag(0,8) == 250;
	question = "Lady Keria is dead.";
	text1 = "Lord Kato licks his lips nervously. _My daughter is in Megiddo Tower, protected by the Watchmen and General Seth; I don't believe you. Whatever sick trickery this is, I refuse to believe it._";
	text2 = "He turns back to his papers. That seems to be that.";
	action = END_TALK;