// creator  : weidu.exe (version 23100)
// argument : BERRUN.DLG
// game		 : .
// source	 : ./DATA/DIALOG.BIF
// dialog	 : ./DIALOG.TLK
// dialogF  : (none)

BEGIN ~BERRUN~
//////////////////////////////////////////////////
// WARNING: this file contains non-trivial WEIGHTs
//////////////////////////////////////////////////

IF WEIGHT #0 ~NumTimesTalkedTo(0)
InParty("JAHEIRA")
!Dead("Jaheira")
~ THEN BEGIN 0 // from:
  SAY #19373 /* ~Actually, no... I am just curious.~ */
  IF ~~ THEN REPLY #19374 /* ~I much prefer liberating the man of his belongings.  Excuse me while I continue.~ */ GOTO 4
  IF ~~ THEN REPLY #19393 /* ~Why do you need this?~ */ GOTO 7
  IF ~~ THEN REPLY #19396 /* ~Limited Wish~ */ GOTO 6
END

IF WEIGHT #1 ~NumTimesTalkedTo(0)
InParty("KHALID")
!Dead("Khalid")
~ THEN BEGIN 1 // from:
  SAY #19378 /* ~You dare to challenge the might of the Cowled Wizards?!~ */
  IF ~~ THEN REPLY #19382 /* ~I might be.  What is in it for me?~ */ GOTO 5
  IF ~~ THEN REPLY #19395 /* ~I'll not allow you to take anything from me, wizard.~ */ GOTO 7
  IF ~~ THEN REPLY #19397 /* ~You have noticed the prevailing attitude against magic in Athkatla, yes?  If we allow this murderer to remain free many will think they can take arms against us.~ */ GOTO 6
END

IF WEIGHT #2 ~NumTimesTalkedTo(0)
InParty("XZAR")
!Dead("Xzar")
~ THEN BEGIN 2 // from:
  SAY #19379 /* ~I... I see.  We are more than a little interested in finding this murderer.  Perhaps you might be amenable to assisting us in this endeavour?~ */
  IF ~~ THEN REPLY #19400 /* ~Very well.  I shall do as you ask.~ */ GOTO 8
  IF ~~ THEN REPLY #19401 /* ~No, I've no interest in hunting this man for you.  Find someone else to perform this task.~ */ GOTO 9
  IF ~~ THEN REPLY #19402 /* ~Ah, the reward.  Adventurers have much use for items the Cowled Wizards possess.  It is sad that magic is so despised in Athkatla, for it has many uses.~ */ GOTO 10
END

IF WEIGHT #3 ~NumTimesTalkedTo(0)
InParty("MONTARON")
!Dead("Montaron")
~ THEN BEGIN 3 // from:
  SAY #19380 /* ~Why do you need help in finding him?~ */
  IF ~~ THEN REPLY #19403 /* ~We will offer you an item of substantial magical power as well as a good deal of gold coin.  What say you, then... will you find this man for us?~ */ GOTO 8
  IF ~~ THEN REPLY #19404 /* ~I would like to know why you think I can find Valygar better than you can.~ */ GOTO 9
  IF ~~ THEN REPLY #19405 /* ~Your order arrested a friend of mine: Imoen.  Tell me where she is and I might consider your task.~ */ GOTO 10
END

IF ~~ THEN BEGIN 4 // from: 0.0
  SAY #19385 /* ~We require one such as yourself to assist us in finding this Valygar.  Would you be amenable to undertaking such a task?~ */
  IF ~~ THEN REPLY #19412 /* ~Very well, then.  I agree to perform this task.~ */ GOTO 11
  IF ~~ THEN REPLY #19413 /* ~I cannot put it aside, and I refuse to work for you unless you tell me where she is.~ */ GOTO 6
END

IF ~~ THEN BEGIN 5 // from: 1.0
  SAY #19387 /* ~Why would you need my assistance?~ */
  IF ~~ THEN REPLY #19417 /* ~Very well... here you go.~ */ GOTO 11
  IF ~~ THEN REPLY #19418 /* ~I will not!~ */ GOTO 6
END

IF ~~ THEN BEGIN 6 // from: 5.1 4.1 1.2 0.2
  SAY #19398 /* ~The Cowled Wizards have worked tirelessly to maintain our hold, here.  But... the commoners refuse to speak to us.  They might speak to you.~ */
  IF ~~ THEN REPLY #19422 /* ~I am no murderer!  I shall not perform this task!~ */ GOTO 12
  IF ~~ THEN REPLY #19423 /* ~Yes, I understand.  This is not a problem.~ */ GOTO 13
END

IF ~~ THEN BEGIN 7 // from: 1.1 0.1
  SAY #19399 /* ~And what might my reward be for performing such a task?~ */
  IF ~~ THEN REPLY #19426 /* ~This machine buzzes with electrical energy.~ */ GOTO 12
  IF ~~ THEN REPLY #19427 /* ~Hmph.  Such a declaration is dangerous, my <LADYLORD>.   The Cowled Wizards will not treat treachery lightly.  Perform your task,  or things will get... unpleasant.~ */ GOTO 13
END

IF ~~ THEN BEGIN 8 // from: 3.0 2.0
  SAY #19406 /* ~Very well, I agree to do this task for you.~ */
  IF ~~ THEN JOURNAL #19432 /* ~The prophecy of Sekolah

I have spoken to the rebel, Prince Villynaty, and agreed with his plan to help overthrow the mad Sahuagin King.  I am to bring the King a false heart.  Then, while the King is so greedily unprepared, Villynaty and his men will attack.  I am to wait until then before I attack the King or any of his guards.~ */ EXIT
END

IF ~~ THEN BEGIN 9 // from: 3.1 2.1
  SAY #19407 /* ~Forget it.  I have no interest in this.~ */
  IF ~~ THEN REPLY #19428 /* ~We will if need be.  This is a delicate matter,  we shall not allow it to be dealt with callously.  Perform your task, and do so quickly, or suffer our wrath.~ */ GOTO 12
  IF ~~ THEN REPLY #19429 /* ~Excellent.  I expect nothing less.  I await the sight of this murderer's body soon.~ */ GOTO 13
END

IF ~~ THEN BEGIN 10 // from: 3.2 2.2
  SAY #19384 /* ~Still, the man is a murderer.  The Cowled Wizards cannot allow one such as he to run free or all in this city will think it permissible to stand against us.~ */
  IF ~~ THEN REPLY #19430 /* ~I will not.  Find someone else to do your dirty work!~ */ GOTO 12
  IF ~~ THEN REPLY #19431 /* ~As you step through the doorway, an alarm sounds and then abruptly stops.~ */ GOTO 13
END

IF ~~ THEN BEGIN 11 // from: 5.0 4.0
  SAY #19420 /* ~Once you have Valygar in custody, bring him to me.  I shall wait here in this building, as I doubt you could locate the Cowled Wizards' headquarters.~ */
  IF ~~ THEN JOURNAL #19432 /* ~The prophecy of Sekolah

I have spoken to the rebel, Prince Villynaty, and agreed with his plan to help overthrow the mad Sahuagin King.  I am to bring the King a false heart.  Then, while the King is so greedily unprepared, Villynaty and his men will attack.  I am to wait until then before I attack the King or any of his guards.~ */ EXIT
END

IF ~~ THEN BEGIN 12 // from: 10.0 9.0 7.0 6.0
  SAY #19424 /* ~This room is dominated by mineral deposits and crystals. It seems to be a natural cavern that this strange prison has been built around. The air holds an aura of power and several pools with swirling lights grace the edge of the rough cavern.~ */
  IF ~~ THEN JOURNAL #19432 /* ~The prophecy of Sekolah

I have spoken to the rebel, Prince Villynaty, and agreed with his plan to help overthrow the mad Sahuagin King.  I am to bring the King a false heart.  Then, while the King is so greedily unprepared, Villynaty and his men will attack.  I am to wait until then before I attack the King or any of his guards.~ */ EXIT
END

IF ~~ THEN BEGIN 13 // from: 10.1 9.1 7.1 6.1
  SAY #19425 /* ~I wish to know something.  Members of your order arrested a friend of mine: Imoen.  I would know where she is before I agree to anything.~ */
  IF ~~ THEN JOURNAL #19432 /* ~The prophecy of Sekolah

I have spoken to the rebel, Prince Villynaty, and agreed with his plan to help overthrow the mad Sahuagin King.  I am to bring the King a false heart.  Then, while the King is so greedily unprepared, Villynaty and his men will attack.  I am to wait until then before I attack the King or any of his guards.~ */ EXIT
END

IF WEIGHT #8 /* Triggers after states #: 15 16 17 19 even though they appear after this state */
~True()
~ THEN BEGIN 14 // from:
  SAY #19436 /* ~Yes, well, calm down for the moment, if ye will. I am well versed in the events that have occurred, and I have but a simple question to put to ye.~ */
  IF ~~ THEN EXIT
END

IF WEIGHT #5 /* Triggers after states #: 19 even though they appear after this state */
~PartyHasItem("MISC85")
~ THEN BEGIN 15 // from:
  SAY #19437 /* ~We met among the Harpers, did we not?  I am through with them.  Many a decent person I met, but damned if I'll be crucified for the failures of their own.~ */
  IF ~~ THEN DO ~ReputationInc(1)
GivePartyGold(900)
AddexperienceParty(1000)
TakePartyItem("MISC85")
TakePartyItem("SCRL2W")
EscapeArea()
~ JOURNAL #19438 /* ~Inside the Drow City

I have been discovered, and the alarm has been sounded throughout the drow city.  Getting anywhere will be problematic, at best.  Obviously I should have been more careful.~ */ EXIT
END

IF WEIGHT #6 /* Triggers after states #: 19 even though they appear after this state */
~PartyHasItem("SCRL2W")
~ THEN BEGIN 16 // from:
  SAY #19439 /* ~Oh, this will clear up a great many things. I care little for the specifics of what occurred in the Harper hold. No, Jaheira, I've a question of a different sort to ask.~ */
  IF ~~ THEN DO ~GivePartyGold(900)
AddexperienceParty(1000)
TakePartyItem("MISC85")
TakePartyItem("SCRL2W")
EscapeArea()
~ EXIT
END

IF WEIGHT #7 /* Triggers after states #: 19 even though they appear after this state */
~PartyHasItem("SCRL2W")
~ THEN BEGIN 17 // from:
  SAY #19681 /* ~Jaheira judged by the Harpers.

The man who gave me Jaheira's note returned, appearing to have full knowledge of the incident with Galvarey and Dermin, and more than a little knowledge of myself.  His only concern was to ask Jaheira if she regretted her actions... and she did not.
Jaheira's steadfast belief in her cause appears to have won the day.  The Harpers have judged the matter closed and will not pursue me further... and on top of this, Jaheira has been given a Harper Pin, an honor that not all Harpers can claim.
And it appears that 'Terminsel' turned out to be none other than Elminster himself.  Odd, I have heard he does not usually get involved in such things.  His interest in those in my company is quite curious.~ */
  IF ~~ THEN DO ~GivePartyGold(900)
AddexperienceParty(1000)
TakePartyItem("MISC85")
TakePartyItem("SCRL2W")
EscapeArea()
~ EXIT
END

IF ~~ THEN BEGIN 18 // from:
  SAY #19682 /* ~Free Jan Jansen from prison.

I was approached by a, er, turnip salesman named Jan Jansen... who was promptly arrested by a guardsman for selling illegal items.  The gnome pleaded with me as he was dragged away to pay the 800 gp fine and break him out of prison, promising to be my, ah, humble servant forever if I do.~ */
  IF ~~ THEN EXIT
END

IF WEIGHT #4 ~NumTimesTalkedTo(0)
~ THEN BEGIN 19 // from:
  SAY #751 /* ~Is there something else I can do? Speak freely if there is.~ */
  IF ~~ THEN EXIT
END
