///////////////////////////////////////////////////////////////////
// Kickout Dialogue for the Xan
///////////////////////////////////////////////////////////////////
BEGIN MOXANP

IF ~HappinessLT(Myself,UNHAPPY_ANGRY_BOUNDARY)~ THEN BEGIN 0
  SAY @9027
  IF ~~ THEN DO ~SetGlobal("KickedOut","LOCALS",1)
EscapeArea()~ EXIT
END

IF ~!HappinessLT(Myself,UNHAPPY_ANGRY_BOUNDARY)
Global("KickedOut","LOCALS",0)~ THEN BEGIN 1
  SAY @9028
  IF ~~ THEN DO ~SetGlobal("KickedOut","LOCALS",1)
ChangeAIScript("",DEFAULT)~ EXIT
END

IF ~!HappinessLT(Myself,UNHAPPY_ANGRY_BOUNDARY)
Global("KickedOut","LOCALS",1)~ THEN BEGIN 2
  SAY @9029
  IF ~~ THEN REPLY @9030 GOTO 4  // I would tend to agree. Perhaps we should rejoin and continue on our way.
  IF ~~ THEN REPLY @9031 GOTO 3  // Work that shall have to wait, I'm afraid. I do not wish to have you back just yet.
END

IF ~~ THEN BEGIN 3
  SAY @9033
  IF ~~ THEN DO ~SetGlobal("KickedOut","LOCALS",1)
ChangeAIScript("",DEFAULT)~ EXIT
END

IF ~~ THEN BEGIN 4
  SAY @9032
  IF ~~ THEN DO ~SetGlobal("KickedOut","LOCALS",0)
JoinParty()~ EXIT
END