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

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

IF ~~ THEN BEGIN 0 // from:
  SAY #24053 /* ~So you have returned. I have trouble seeing why you would do so. Your callous disregard for my sister's life does not endear you to me.~ */
  IF ~ReactionGT(LastTalkedToBy,HOSTILE_UPPER)~ THEN REPLY #24056 /* ~We came to apologize for being insensitive. I came to ask you to rejoin my party.~ */ GOTO 5
  IF ~~ THEN REPLY #24057 /* ~It matters not to me if I endear myself to you.~ */ GOTO 3
  IF ~ReactionLT(LastTalkedToBy,NEUTRAL_LOWER)~ THEN REPLY #24205 /* ~I apologize for not helping your sister. I would like you to rejoin my party.~ */ GOTO 4
END

IF ~~ THEN BEGIN 1 // from: 3.0
  SAY #24054 /* ~Then do so.~ */
  IF ~~ THEN EXIT
END

IF ~~ THEN BEGIN 2 // from: 3.1
  SAY #24055 /* ~Heartless wretch!~ */
  IF ~~ THEN DO ~ReputationInc(-1)
Enemy()~ EXIT
END

IF ~~ THEN BEGIN 3 // from: 0.1
  SAY #24206 /* ~Then you have no business being here. Begone!~ */
  IF ~~ THEN REPLY #24207 /* ~I will leave.~ */ GOTO 1
  IF ~~ THEN REPLY #24208 /* ~Do not order me about like a lapdog. I'm not leaving.~ */ GOTO 2
END

IF ~~ THEN BEGIN 4 // from: 0.2
  SAY #24210 /* ~If you wish me to return to your party, you shall have to have a reputation as a righteous person. You are not known to be righteous at present.~ */
  IF ~~ THEN EXIT
END

IF ~~ THEN BEGIN 5 // from: 0.0
  SAY #24211 /* ~I accept your apology and I shall return to your party, though I caution you against betraying my trust for a second time.~ */
  IF ~~ THEN DO ~SetGlobal("MazzyNoCure","GLOBAL",0)
JoinParty()~ EXIT
END

IF ~~ THEN BEGIN 6 // from: 33.1
  SAY #46861 /* ~I should have liked to stay but it is not to be, I shall return to my home in Trademeet. If you have need of me again, I shall be happy to join with you again. Farewell.~ */
  IF ~~ THEN DO ~SetGlobal("KickedOut","LOCALS",1)
SetGlobal("MazzyHappy","GLOBAL",1)
RevealAreaOnMap("AR2000")
EscapeAreaMove("AR2002",341,400,12)~ EXIT
END

IF ~~ THEN BEGIN 7 // from:
  SAY #46862 /* ~Well met, <CHARNAME>. I trust that, by your being here, you've defeated the Shade Lord.~ */
  IF ~Dead("shadel")~ THEN REPLY #46863 /* ~We have indeed defeated him. Did your journey home go well?~ */ DO ~SetGlobal("ShTrade","GLOBAL",2)~ GOTO 8
  IF ~Dead("shadel")~ THEN REPLY #46873 /* ~The creature is dead, no thanks to you.~ */ DO ~SetGlobal("ShTrade","GLOBAL",2)~ GOTO 13
  IF ~!Dead("shadel")~ THEN REPLY #46956 /* ~The creature is not yet dead.~ */ DO ~SetGlobal("ShTrade","GLOBAL",2)~ GOTO 24
END

IF ~~ THEN BEGIN 8 // from: 7.0
  SAY #46864 /* ~The journey went well, though the thought of my slain companions weighed heavy on me. It is good to know that you've avenged their foul end.~ */
  IF ~~ THEN REPLY #46865 /* ~To be honest, I don't care about your useless friends. I killed the Shade Lord only for the joy of it.~ */ GOTO 9
  IF ~~ THEN REPLY #46867 /* ~Many souls were avenged when we destroyed the Shade Lord. What do you do now?~ */ GOTO 10
END

IF ~~ THEN BEGIN 9 // from: 8.0
  SAY #46866 /* ~That is a cruel thing to say. Perhaps it is better that I did not join you back in that evil cave. If this was a social visit then it has ended. Begone from my abode!~ */
  IF ~~ THEN DO ~SetGlobal("MazzyAngry","GLOBAL",1)~ EXIT
END

IF ~~ THEN BEGIN 10 // from: 8.1
  SAY #46868 /* ~At present I am on sabbatical. I find myself missing the road and I long again for adventure. Does your party require another sword arm?~ */
  IF ~~ THEN REPLY #46869 /* ~Not at this time, good halfling. Though, should we have need we shall surely call on you.~ */ GOTO 11
  IF ~~ THEN REPLY #46871 /* ~I would be pleased to have you join my party.~ */ GOTO 12
END

IF ~~ THEN BEGIN 11 // from: 14.0 10.0
  SAY #46870 /* ~I do grow weary of being about the house and I long to adventure once more. Should you require me in the future, I shall be here.~ */
  IF ~~ THEN DO ~SetGlobal("MazzyHappy","GLOBAL",1)~ EXIT
END

IF ~~ THEN BEGIN 12 // from: 10.1
  SAY #46872 /* ~I am happy to join your party.~ */
  IF ~~ THEN DO ~JoinParty()
SetGlobalTimer("SpawnDannoTimer","GLOBAL",FIFTEEN_DAYS)~ EXIT
END

IF ~~ THEN BEGIN 13 // from: 7.1
  SAY #46874 /* ~That is a cruel thing to say. It would have done no good to face him without your support. If this was a social visit then it has ended. Begone from my abode!~ */
  IF ~~ THEN DO ~SetGlobal("MazzyAngry","GLOBAL",1)~ EXIT
END

IF WEIGHT #1 /* Triggers after states #: 35 even though they appear after this state */
~Global("MazzyHappy","GLOBAL",1)
Global("KickedOut","LOCALS",1)
~ THEN BEGIN 14 // from:
  SAY #46875 /* ~You have returned, I see. What is it that you need?~ [MAZZY91] */
  IF ~~ THEN REPLY #46876 /* ~We need nothing at this time.~ */ GOTO 11
  IF ~~ THEN REPLY #46877 /* ~I should be honored to have you join my party.~ */ GOTO 15
END

IF ~~ THEN BEGIN 15 // from: 14.1
  SAY #46878 /* ~In truth, since we last met, I have considered again raising up a party on my own, though it is a terrible bother. I shall come with you, then.~ */
  IF ~~ THEN DO ~SetGlobal("MazzyHappy","GLOBAL",0)
SetGlobalTimer("SpawnDannoTimer","GLOBAL",FIFTEEN_DAYS)
SetGlobal("KickedOut","LOCALS",0)
JoinParty()
~ EXIT
END

IF WEIGHT #2 /* Triggers after states #: 35 even though they appear after this state */
~GlobalGT("Pala","GLOBAL",0)
Global("KickedOut","LOCALS",0)
Global("PalaCureFound","GLOBAL",0)
~ THEN BEGIN 16 // from:
  SAY #46879 /* ~How can you leave me like this while my sister lies dying? Will you not reconsider? I need your help!~ [MAZZY92] */
  IF ~~ THEN REPLY #46880 /* ~That is a good point, Mazzy. My apologies. I will help you and your sister.~ */ DO ~SetGlobal("KickedOut","LOCALS",1)
~ GOTO 18
  IF ~~ THEN REPLY #46881 /* ~I'm sorry but this isn't my concern.~ */ DO ~SetGlobal("KickedOut","LOCALS",1)
~ GOTO 17
  IF ~~ THEN REPLY #46882 /* ~Are you still here, halfling? Run along now. You grow tiresome.~ */ DO ~SetGlobal("KickedOut","LOCALS",1)
~ GOTO 17
END

IF ~~ THEN BEGIN 17 // from: 16.2 16.1
  SAY #46883 /* ~You brutish <PRO_RACE>! I shall never wish to see you again! I will find a antidote for Pala's poison myself!~ */
  IF ~~ THEN DO ~SetGlobal("MazzyNoCure","GLOBAL",1)~ EXIT
END

IF ~~ THEN BEGIN 18 // from: 16.0
  SAY #46884 /* ~An isolated slip of logic, I'm sure.~ */
  IF ~~ THEN DO ~JoinParty()~ EXIT
END

IF WEIGHT #3 /* Triggers after states #: 35 even though they appear after this state */
~Global("PalaCureFound","GLOBAL",3)
!GlobalTimerExpired("PalaWakeUp","GLOBAL")~ THEN BEGIN 19 // from:
  SAY #46895 /* ~Return in a few hours. I must wait until Pala awakens before I can go.~ [MAZZY93] */
  IF ~~ THEN EXIT
END

IF WEIGHT #4 /* Triggers after states #: 35 even though they appear after this state */
~Global("PalaCureFound","GLOBAL",3)
GlobalTimerExpired("PalaWakeUp","GLOBAL")~ THEN BEGIN 20 // from:
  SAY #46929 /* ~Welcome back. I am ready to leave if you are.~ [MAZZY94] */
  IF ~~ THEN REPLY #46930 /* ~Pala is better, I see.~ */ DO ~SetGlobal("PalaCureFound","GLOBAL",4)~ GOTO 21
  IF ~~ THEN REPLY #46931 /* ~We no longer have need of your services.~ */ DO ~SetGlobal("PalaCureFound","GLOBAL",4)~ GOTO 22
END

IF ~~ THEN BEGIN 21 // from: 20.0
  SAY #46932 /* ~Indeed. My thanks for your assistance in this difficult time.~ */
  IF ~~ THEN REPLY #46933 /* ~Then let us depart. We have much to accomplish out in the world.~ */ GOTO 23
  IF ~~ THEN REPLY #46934 /* ~I wish you well, in that case. There is no need for you to join the party at this time.~ */ GOTO 22
END

IF ~~ THEN BEGIN 22 // from: 21.1 20.1
  SAY #46935 /* ~As you will it, so shall it be. If you have need of me in the future. I shall be here. I thank you again.~ */
  IF ~~ THEN DO ~SetGlobal("KickedOut","LOCALS",1)
SetGlobal("MazzyHappy","GLOBAL",1)~ EXIT
END

IF ~~ THEN BEGIN 23 // from: 21.0
  SAY #46936 /* ~I am happy to join you.~ */
  IF ~~ THEN DO ~JoinParty()~ EXIT
END

IF ~~ THEN BEGIN 24 // from: 7.2
  SAY #46957 /* ~This is not good. If you will take me I will rejoin you and we shall hunt the Shade Lord down and destroy him.~ */
  IF ~~ THEN REPLY #46958 /* ~Thank you but I have no need for your help.~ */ GOTO 25
  IF ~~ THEN REPLY #46959 /* ~An excellent idea, Mazzy. Join with me and we shall conquer!~ */ GOTO 26
  IF ~~ THEN REPLY #46960 /* ~I hardly need a halfling to fight a battle. Stay at home and bake or something.~ */ GOTO 27
END

IF ~~ THEN BEGIN 25 // from: 24.0
  SAY #46961 /* ~As you will. I wish you luck.~ */
  IF ~~ THEN DO ~SetGlobal("MazzyHappy","GLOBAL",1)~ EXIT
END

IF ~~ THEN BEGIN 26 // from: 24.1
  SAY #46962 /* ~I am happy to join you.~ */
  IF ~~ THEN DO ~JoinParty()~ EXIT
END

IF ~~ THEN BEGIN 27 // from: 24.2
  SAY #46963 /* ~What a foolish thing to say! You should think before you allow such drivel to come from your lips. Leave my house!~ */
  IF ~~ THEN DO ~SetGlobal("MazzyAngry","GLOBAL",1)~ EXIT
END

IF ~~ THEN BEGIN 28 // from:
  SAY #46964 /* ~You are the last person that I wish to see. How rude can one be?~ [MAZZY75] */
  IF ~ReactionGT(LastTalkedToBy,HOSTILE_UPPER)~ THEN REPLY #46965 /* ~I realize that I've been less than polite. I've come back to apologize and ask you to join my party.~ */ GOTO 29
  IF ~~ THEN REPLY #46966 /* ~I care not, halfling.~ */ GOTO 31
  IF ~ReactionLT(LastTalkedToBy,NEUTRAL_LOWER)~ THEN REPLY #46967 /* ~I realize that I've been less than polite. I've come back to apologize and ask you to join my party.~ */ GOTO 30
END

IF ~~ THEN BEGIN 29 // from: 28.0
  SAY #46968 /* ~I accept your apology. Occasionally a bit of goodness shines through your mask of indifferent rudeness. I shall rejoin me but I warn you against being so offensive in the future.~ */
  IF ~~ THEN DO ~SetGlobal("MazzyAngry","GLOBAL",0)
SetGlobalTimer("SpawnDannoTimer","GLOBAL",FIFTEEN_DAYS)
Global("KickedOut","LOCALS",1)
JoinParty()
~ EXIT
END

IF ~~ THEN BEGIN 30 // from: 28.2
  SAY #46969 /* ~It may be as you say yet your reputation precedes you. Prove yourself worthy and return to me when you are known to be righteous to the world at large.~ */
  IF ~~ THEN EXIT
END

IF ~~ THEN BEGIN 31 // from: 28.1
  SAY #46970 /* ~Leave my house!~ */
  IF ~~ THEN EXIT
END

IF WEIGHT #5 /* Triggers after states #: 35 even though they appear after this state */
~HappinessLT(Myself,-299)
~ THEN BEGIN 32 // from:
  SAY #48669 /* ~You have proven yourself to be a person of few morals. I'm happy that I am leaving.~ [MAZZY95] */
  IF ~~ THEN DO ~EscapeArea()
~ EXIT
END

IF WEIGHT #6 /* Triggers after states #: 35 even though they appear after this state */
~Global("KickedOut","LOCALS",0)
~ THEN BEGIN 33 // from:
  SAY #48680 /* ~Are you sure that you wish me to leave? There is still much good that we need to accomplish in this place.~ [MAZZY96] */
  IF ~~ THEN REPLY #48682 /* ~I would rather have you stay with the party.~ */ DO ~JoinParty()
~ EXIT
  IF ~GlobalLT("chapter","GLOBAL",7)
Dead("Shadel")
~ THEN REPLY #48683 /* ~I think it best that we go on alone.~ */ GOTO 6
  IF ~GlobalLT("chapter","GLOBAL",7)
!Dead("Shadel")
~ THEN REPLY #48687 /* ~I think it best that we go on alone.~ */ GOTO 34
END

IF ~~ THEN BEGIN 34 // from: 33.2
  SAY #48690 /* ~I would have liked to stay. Please, at least, avenge my friends and destroy the Shade Lord. I shall return to my home in Trademeet. Farewell and good luck.~ */
  IF ~~ THEN DO ~SetGlobal("KickedOut","LOCALS",1)
RevealAreaOnMap("AR2000")
SetGlobal("MazzyHappy","GLOBAL",1)
EscapeAreaMove("AR2002",341,400,12)
~ EXIT
END

IF WEIGHT #0 ~Global("MazzyNoCure","GLOBAL",1)~ THEN BEGIN 35 // from:
  SAY #61541 /* ~Begone from my sight.  You have proven yourself unworthy of my friendship.~ */
  IF ~~ THEN EXIT
END
