// creator  : weidu.exe (version 23100)
// argument : AERIEP.DLG
// game		 : .
// source	 : ./override/AERIEP.DLG
// dialog	 : ./DIALOG.TLK
// dialogF  : (none)

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

IF WEIGHT #3 /* Triggers after states #: 8 14 16 even though they appear after this state */
~Global("KickedOut","LOCALS",1)
Dead("Kalah")~ THEN BEGIN 0 // from:
  SAY #2305 /* ~Hello.~ [AERIEC3] */
  IF ~HappinessGT(Myself,-289)~ THEN REPLY #2588 /* ~Hello, Aerie.  Would you like to travel with us again?~ */ GOTO 1
  IF ~HappinessGT(Myself,-289)
!Dead("quaylem")
!Dead("quayle")~ THEN REPLY #61068 /* ~Greetings.  I trust everything is alright, here?~ */ GOTO 17
  IF ~HappinessGT(Myself,-289)
OR(2)
Dead("quaylem")
Dead("quayle")~ THEN REPLY #61069 /* ~Greetings.  I trust everything is alright, here?~ */ GOTO 18
  IF ~HappinessLT(Myself,-290)~ THEN REPLY #61072 /* ~Hello, Aerie.  Would you like to travel with me again?~ */ GOTO 19
  IF ~HappinessLT(Myself,-290)~ THEN REPLY #2590 /* ~Hello, Aerie... How have you been?~ */ GOTO 3
END

IF ~~ THEN BEGIN 1 // from: 0.0
  SAY #2591 /* ~There is nothing else for me to do... Aye, what choice have I?~ */
  IF ~~ THEN DO ~SetGlobal("KickedOut","LOCALS",0)
JoinParty()
~ EXIT
END

IF ~~ THEN BEGIN 2 // from:
  SAY #2592 /* ~How could I travel with you? You of all people should know not to ask... My home is this circus and all else is madness... Take care out there but I'll not be with you...~ */
  IF ~~ THEN EXIT
END

IF ~~ THEN BEGIN 3 // from: 0.4
  SAY #2593 /* ~Time passes, the people walk by... but at least I've been able to stay here at the circus.  Take care, <GABBER>...~ */
  IF ~~ THEN EXIT
END

IF ~~ THEN BEGIN 4 // from: 12.0 9.1 6.1
  SAY #2594 /* ~I... I guess I'll go back to the circus, then. You'll come visit me there, won't you?~ */
  IF ~!AreaCheck("AR0602")
!AreaCheck("AR0603")
!AreaCheck("AR0410")
!AreaCheck("AR0411")
!AreaCheck("AR0412")
!AreaCheck("AR0413")
!AreaCheck("AR0414")
!AreaCheck("AR1512")
!AreaCheck("AR1513")
!AreaCheck("AR1514")
!AreaCheck("AR1515")
!AreaCheck("AR1516")
!AreaCheck("AR1501")
!AreaCheck("AR1502")
!AreaCheck("AR1503")
!AreaCheck("AR1504")
!AreaCheck("AR1505")
!AreaCheck("AR1506")
!AreaCheck("AR1507")
!AreaCheck("AR1508")
!AreaCheck("AR1509")
!AreaCheck("AR1510")
!AreaCheck("AR1511")
!AreaCheck("AR2100")
!AreaCheck("AR2101")
!AreaCheck("AR2102")
!AreaCheck("AR2200")
!AreaCheck("AR2202")
!AreaCheck("AR2203")
!AreaCheck("AR2204")
!AreaCheck("AR2205")
!AreaCheck("AR2206")
!AreaCheck("AR2207")
!AreaCheck("AR2208")
!AreaCheck("AR2209")
!AreaCheck("AR2210")
!AreaCheck("AR2300")
!AreaCheck("AR2400")
!AreaCheck("AR2401")
!AreaCheck("AR2402")
!AreaCheck("AR2900")
!AreaCheck("AR2901")
!AreaCheck("AR2902")
!AreaCheck("AR2903")
!AreaCheck("AR2904")
!AreaCheck("AR2905")
!AreaCheck("AR2906")
~ THEN REPLY #49740 /* ~Yes, return to the circus.  If we need you again, we'll come and get you.~ */ DO ~SetGlobal("KickedOut","LOCALS",1)
MoveGlobal("AR0607","Aerie",[469.437])
~ EXIT
  IF ~!AreaCheck("AR0301")
!AreaCheck("AR0302")
!AreaCheck("AR0303")
!AreaCheck("AR0304")
!AreaCheck("AR0305")
!AreaCheck("AR0306")
!AreaCheck("AR0307")
!AreaCheck("AR0509")
!AreaCheck("AR0510")
!AreaCheck("AR0511")
!AreaCheck("AR1102")
!AreaCheck("AR1107")
!AreaCheck("AR0801")
!AreaCheck("AR0803")
!AreaCheck("AR1300")
!AreaCheck("AR1301")
!AreaCheck("AR1302")
!AreaCheck("AR1303")
!AreaCheck("AR0604")
!AreaCheck("AR0605")
!AreaCheck("AR0606")
!InWatchersKeep()
~ THEN REPLY #49741 /* ~You can't go to the circus.  Just wait here, and we'll come back when we need you.~ */ DO ~SetGlobal("KickedOut","LOCALS",1)
~ EXIT
END

IF WEIGHT #4 /* Triggers after states #: 8 14 16 even though they appear after this state */
~Global("KickedOut","LOCALS",0)
HappinessLT(Myself,-290)
~ THEN BEGIN 5 // from:
  SAY #2595 /* ~I--I never should have let you take me from the circus! You're all heartless, every last one of you!~ [AERIEC4] */
  IF ~~ THEN DO ~LeaveParty()
SetGlobal("KickedOut","LOCALS",1)
EscapeAreaMove("AR0607",469,437,0)
~ EXIT
END

IF WEIGHT #5 /* Triggers after states #: 8 14 16 even though they appear after this state */
~Global("KickedOut","LOCALS",0)
Dead("Kalah")~ THEN BEGIN 6 // from:
  SAY #48306 /* ~I am sure you want to continue as we were?~ [AERIEC5] */
  IF ~~ THEN REPLY #48307 /* ~Yes, let's get going, Aerie.~ */ GOTO 7
  IF ~~ THEN REPLY #48308 /* ~No, I think we should split up for now.~ */ GOTO 4
END

IF ~~ THEN BEGIN 7 // from: 16.0 6.0
  SAY #48310 /* ~Good. There isn't anywhere else I would rather be.~ */
  IF ~~ THEN DO ~JoinParty()
~ EXIT
END

IF WEIGHT #0 ~Global("AerieVampire","GLOBAL",5)
~ THEN BEGIN 8 // from:
  SAY #56598 /* ~You rescued me! Oh, I knew you would. That's why I care about you, you know. You never let your loved ones down.~ [AERIEC6] */
  IF ~~ THEN REPLY #56650 /* ~Stow it, Aerie. We've got to get moving and there's no time for this.~ */ DO ~EraseJournalEntry(32084)
EraseJournalEntry(32085)
EraseJournalEntry(16351)
EraseJournalEntry(7002)
EraseJournalEntry(3716)
EraseJournalEntry(5814)
EraseJournalEntry(16331)
EraseJournalEntry(15710)
EraseJournalEntry(6589)
EraseJournalEntry(11864)
EraseJournalEntry(3374)
EraseJournalEntry(3377)
EraseJournalEntry(3927)
SetGlobal("AerieVampire","GLOBAL",6)
~ SOLVED_JOURNAL #6555 /* ~The Final Battle with Bodhi.

While I had feared for some time that Bodhi's final revenge on me would be to take away Aerie forever, it seems that the information in the lorebook was right... Amaunator's idol has restored Aerie not only to life, but has removed the vampiric curse from her, as well.~ */ GOTO 9
  IF ~~ THEN REPLY #56651 /* ~I missed you terribly. I could not bear to think of you suffering such a fate as this.~ */ DO ~EraseJournalEntry(32084)
EraseJournalEntry(32085)
EraseJournalEntry(16351)
EraseJournalEntry(7002)
EraseJournalEntry(3716)
EraseJournalEntry(5814)
EraseJournalEntry(16331)
EraseJournalEntry(15710)
EraseJournalEntry(6589)
EraseJournalEntry(11864)
EraseJournalEntry(3374)
EraseJournalEntry(3377)
EraseJournalEntry(3927)
SetGlobal("AerieVampire","GLOBAL",6)
~ SOLVED_JOURNAL #6555 /* ~The Final Battle with Bodhi.

While I had feared for some time that Bodhi's final revenge on me would be to take away Aerie forever, it seems that the information in the lorebook was right... Amaunator's idol has restored Aerie not only to life, but has removed the vampiric curse from her, as well.~ */ GOTO 11
  IF ~~ THEN REPLY #56652 /* ~Now don't get all mushy, I just did what I thought I had to. I... I missed you too, Aerie.~ */ DO ~EraseJournalEntry(32084)
EraseJournalEntry(32085)
EraseJournalEntry(16351)
EraseJournalEntry(7002)
EraseJournalEntry(3716)
EraseJournalEntry(5814)
EraseJournalEntry(16331)
EraseJournalEntry(15710)
EraseJournalEntry(6589)
EraseJournalEntry(11864)
EraseJournalEntry(3374)
EraseJournalEntry(3377)
EraseJournalEntry(3927)
SetGlobal("AerieVampire","GLOBAL",6)
~ SOLVED_JOURNAL #6555 /* ~The Final Battle with Bodhi.

While I had feared for some time that Bodhi's final revenge on me would be to take away Aerie forever, it seems that the information in the lorebook was right... Amaunator's idol has restored Aerie not only to life, but has removed the vampiric curse from her, as well.~ */ GOTO 11
END

IF ~~ THEN BEGIN 9 // from: 8.0
  SAY #56654 /* ~What? But... but I thought... never mind. Never mind what I thought! Let's just... let's just get going!~ */
  IF ~~ THEN REPLY #56655 /* ~Right you are. No more wasting time.~ */ GOTO 10
  IF ~~ THEN REPLY #56656 /* ~Actually, Aerie, I don't have room for you right now.~ */ GOTO 4
END

IF ~~ THEN BEGIN 10 // from: 9.0
  SAY #56657 /* ~Yes, no wasting time or effort or feelings or... or... nothing.~ */
  IF ~~ THEN DO ~JoinParty()
~ EXIT
END

IF ~~ THEN BEGIN 11 // from: 8.2 8.1
  SAY #56658 /* ~I knew you wouldn't let me down. You followed... and I'll follow you, <CHARNAME>. I'll follow wherever you lead.~ */
  IF ~~ THEN REPLY #56659 /* ~Let's go, Aerie. I want to get back to the sunlight outside. I hope the sky matches your happy mood.~ */ GOTO 13
  IF ~~ THEN REPLY #56660 /* ~That will... have to wait, Aerie. I don't have room for you at the moment. I'm sorry.~ */ GOTO 12
END

IF ~~ THEN BEGIN 12 // from: 11.1
  SAY #56661 /* ~No... no room? But I thought... you just said... never... never mind! Never mind what I thought.~ */
  IF ~~ THEN GOTO 4
END

IF ~~ THEN BEGIN 13 // from: 11.0
  SAY #56662 /* ~I don't care if it does or not, <CHARNAME>. You are my light. That's enough for me.~ */
  IF ~~ THEN DO ~JoinParty()
~ EXIT
END

IF WEIGHT #1 ~Global("KickedOut","LOCALS",0)
!Dead("Kalah")~ THEN BEGIN 14 // from:
  SAY #61061 /* ~But... but everything has not been put right!  Are you sure you want to leave me here?!~ */
  IF ~~ THEN REPLY #61062 /* ~Perhaps not.  Join with me, again.~ */ DO ~JoinParty()~ EXIT
  IF ~~ THEN REPLY #61063 /* ~Yes, stay here for now.~ */ GOTO 15
END

IF ~~ THEN BEGIN 15 // from: 16.1 14.1
  SAY #61064 /* ~Al-alright.  But... please help Quayle!  Something has to be done!~ */
  IF ~~ THEN DO ~SetGlobal("KickedOut","LOCALS",1)~ EXIT
END

IF WEIGHT #2 ~Global("KickedOut","LOCALS",1)
!Dead("Kalah")~ THEN BEGIN 16 // from:
  SAY #61065 /* ~Is everything alright?  Do you want me to come with you again?~ */
  IF ~~ THEN REPLY #61066 /* ~Yes, join up with me again.~ */ GOTO 7
  IF ~~ THEN REPLY #61067 /* ~Everything's fine.  Stay here, for now, Aerie.~ */ GOTO 15
END

IF ~~ THEN BEGIN 17 // from: 0.1
  SAY #61070 /* ~Everything is fine, <GABBER>.  Uncle Quayle is running the circus, although... although I would like to travel on my own, someday.  If you have need of me, I'll be here.~ */
  IF ~~ THEN EXIT
END

IF ~~ THEN BEGIN 18 // from: 0.2
  SAY #61071 /* ~Everything is... alright.  It isn't the same, however, with Quayle dead.  (sigh)  If you... if you have need of me, I'd like to travel away from here, someday.~ */
  IF ~~ THEN EXIT
END

IF ~~ THEN BEGIN 19 // from: 0.3
  SAY #61073 /* ~No, I don't think so.  I'll travel, someday... but I'll do it on my own.  Thank you anyway, <GABBER>.~ */
  IF ~~ THEN EXIT
END
