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

BEGIN ~GNOBLEM2~ 2 // non-zero flags may indicate non-pausing dialogue
//////////////////////////////////////////////////
// WARNING: this file contains non-trivial WEIGHTs
//////////////////////////////////////////////////

IF WEIGHT #4 /* Triggers after states #: 4 5 6 7 even though they appear after this state */
~RandomNum(4,1)
~ THEN BEGIN 0 // from:
  SAY #30049 /* ~(sigh)  The weather is quite lovely today, isn't it?  We Amnish have it perfect, here.  Calimshan is too hot, while Waterdeep is too cold, I believe.~ */
  IF ~~ THEN EXIT
END

IF WEIGHT #5 /* Triggers after states #: 4 5 6 7 even though they appear after this state */
~RandomNum(4,2)
~ THEN BEGIN 1 // from:
  SAY #30051 /* ~Never trust a Waterdhavian, that's my advice.  They see us Amnish as their rivals and will cheat you in any deal if they get half a chance.~ */
  IF ~~ THEN EXIT
END

IF WEIGHT #6 /* Triggers after states #: 4 5 6 7 even though they appear after this state */
~RandomNum(4,3)
~ THEN BEGIN 2 // from:
  SAY #30052 /* ~Such a curious thing.  I've been waiting for my caravan to return from Trademeet for almost a week, now.  I wonder if there is trouble out that way?~ */
  IF ~~ THEN EXIT
END

IF WEIGHT #7 /* Triggers after states #: 4 5 6 7 even though they appear after this state */
~RandomNum(4,4)
~ THEN BEGIN 3 // from:
  SAY #30054 /* ~It is so odd to see Waukeen's faithful being caretaken by the priests of Lliira.  I find the Goddess of Joy's clerics to be far too giddy to be true patrons of business.~ */
  IF ~~ THEN EXIT
END

IF WEIGHT #0 ~InParty("Jaheira")
See("Jaheira")
!StateCheck("Jaheira",STATE_SLEEPING)
RandomNum(2,1)
Global("gnoblem2Jaheira","GLOBAL",0)
~ THEN BEGIN 4 // from:
  SAY #30057 /* ~You there, elven lass... you have the bearing of one of the lovely courtesans I have seen in this wealthy district.  Might I be correct in that observation?~ */
  IF ~~ THEN DO ~SetGlobal("gnoblem2Jaheira","GLOBAL",1)
~ EXTERN ~JAHEIRAJ~ 290
END

IF WEIGHT #1 ~InParty("HaerDalis")
See("HaerDalis")
!StateCheck("HaerDalis",STATE_SLEEPING)
RandomNum(2,1)
Global("gnoblem2HaerDalis","GLOBAL",0)~ THEN BEGIN 5 // from:
  SAY #30063 /* ~Hmm... I have seen you entertaining somewhere, have I not?  Might you be for hire, sir?  I have a rather important function that I am hosting a week from now.~ */
  IF ~~ THEN DO ~SetGlobal("gnoblem2HaerDalis","GLOBAL",1)~ EXTERN ~HAERDAJ~ 47
END

IF WEIGHT #2 ~InParty("Anomen")
See("Anomen")
!StateCheck("Anomen",STATE_SLEEPING)
RandomNum(2,1)
Global("gnoblem2Anomen","LOCALS",0)~ THEN BEGIN 6 // from:
  SAY #50384 /* ~Ah... Anomen Delryn, I see.  If your father has sent you, dear boy, you may tell him that I did not invite him to my last function because --~ */
  IF ~~ THEN DO ~SetGlobal("gnoblem2Anomen","LOCALS",1)~ EXTERN ~ANOMENJ~ 246
END

IF WEIGHT #3 ~InParty("Yoshimo")
See("Yoshimo")
!StateCheck("Yoshimo",STATE_SLEEPING)
RandomNum(2,2)
Global("gnoblem2Yoshimo","LOCALS",0)~ THEN BEGIN 7 // from:
  SAY #50386 /* ~Hmmm... I could have sworn I wore my ring when I left the mansion this morning.  I say... could any of you people have seen it?  Perhaps it fell to the ground?~ */
  IF ~~ THEN DO ~SetGlobal("gnoblem2Yoshimo","LOCALS",1)
GiveItemCreate("ring16","Yoshimo",0,0,0)~ EXTERN ~YOSHJ~ 87
END

IF ~~ THEN BEGIN 8 // from:
  SAY #50403 /* ~Ah... I see.  Thank you very much!  I... I shall be on my way, then...~ */
  IF ~~ THEN DO ~TakePartyItem("ring16")
RunAwayFrom("Yoshimo",50)~ EXIT
END
