IF
Global("RZAR5504","GLOBAL",0)
THEN
RESPONSE #100
SetGlobal("RZAR5504","GLOBAL",1)
Continue()
END
YOUR CODE WAS HERE
IF
OnCreation()
Global("MONKSPAWNEDSMUGGLERPLOT","GLOBAL",2)
Global("FADEDIN","MYAREA",0)
!Global("Enclave","GLOBAL",2)
THEN
RESPONSE #100
FadeToColor([1.0],0)
Wait(2)
FadeFromColor([30.0],0)
SetGlobal("FADEDIN","MYAREA",1)
END
IF
GlobalGT("A7Quest5","GLOBAL",1)
GlobalLT("CaveEnter","AR5504",2)
THEN
RESPONSE #100
IncrementGlobal("CaveEnter","AR5504",1)
END
IF
GlobalGT("A7Quest5","GLOBAL",1)
Global("MONKSPAWNEDSMUGGLERPLOT","GLOBAL",0)
!Global("Enclave","GLOBAL",2)
OR(2)
Allegiance("AMCARRAS",ENEMY)
Dead("AMCARRAS")
THEN
RESPONSE #100
SetGlobal("MONKSPAWNEDSMUGGLERPLOT","GLOBAL",1)
END
IF
GlobalGT("A7Quest5","GLOBAL",1)
Global("MONKSPAWNEDSMUGGLERPLOT","GLOBAL",0)
Global("CaveEnter","AR5504",2)
!Dead("amcarras")
!Allegiance("amcarras",ENEMY)
!HPPercentLT("amcarras",100)
!Global("Enclave","GLOBAL",2)
THEN
RESPONSE #100
CreateCreature("AMMONK02",[682.1034],S) // Monk
CreateCreature("AMMONK04",[541.1021],S) // Monk
CreateCreature("AMMONK05",[559.951],S) // Monk
CreateCreature("AMMONK06",[659.931],S) // Monk
ActionOverride("AMMONK02",FaceObject("AMCARRAS"))
ActionOverride("AMMONK04",FaceObject("AMCARRAS"))
ActionOverride("AMMONK05",FaceObject("AMCARRAS"))
ActionOverride("AMMONK06",FaceObject("AMCARRAS"))
SetGlobal("MONKSPAWNEDSMUGGLERPLOT","GLOBAL",1)
END
IF
Global("Enclave","GLOBAL",2)
Global("SaemonLeave","GLOBAL",0)
Global("PlaceBodies","AR5504",0)
!Dead("amsaemon")
THEN
RESPONSE #100
FadeToColor([20.0],0)
Wait(1)
CreateCreature("AMSAEMON",[861.942],SW) // Saemon Havarian
CreateCreature("DEDSMUG",[527.817],S) // Smuggler
CreateCreature("DEDSMUG",[900.724],E) // Smuggler
CreateCreature("DEDSMUG",[882.1041],SWW) // Smuggler
CreateCreature("DEDSMUG",[669.1002],S) // Smuggler
CreateCreature("DEDSMUG",[802.450],NW) // Smuggler
Wait(1)
FadeFromColor([20.0],0)
Wait(1)
SetGlobal("PlaceBodies","AR5504",1)
END
IF
Global("A7Q5Intro","AR5504",0)
Global("A7Quest5","GLOBAL",0)
Global("A7Q5AfaaqAppears","GLOBAL",0)
Global("A7AfaaqEnslaved","GLOBAL",0)
Global("A7AfaaqSummoned","GLOBAL",0)
PartyHasItem("A7DJLMPA") // Djinni lamp
!Global("Enclave","GLOBAL",2)
THEN
RESPONSE #100
SetGlobal("A7Q5Intro","AR5504",1)
CreateCreature("A7Karim",[481.920],E) // Karim
ActionOverride("A7Karim",FaceObject("AMCARRAS"))
ActionOverride("A7Karim",DestroyItem("A7RING01")) // Sandthief's Ring
CreateCreature("A7Q5DJ01",[518.830],SE) // Djinni
ActionOverride("A7Q5DJ01",SetDialog("A7Q5DJ01"))
ActionOverride("A7Q5DJ01",FaceObject("AMCARRAS"))
ActionOverride("A7Q5DJ01",DestroyItem("A7RING01")) // Sandthief's Ring
CreateCreature("A7Q5DJ05",[424.850],SEE) // Djinni
ActionOverride("A7Q5DJ05",SetDialog("A7Q5DJ05"))
ActionOverride("A7Q5DJ05",FaceObject("AMCARRAS"))
ActionOverride("A7Q5DJ05",DestroyItem("A7RING01")) // Sandthief's Ring
ActionOverride("AMCARRAS",FaceObject("A7Karim"))
Wait(2)
ClearAllActions()
StartCutSceneMode()
StartCutScene("A7Q5ct1a")
END
IF
Global("A7Q5Intro","AR5504",0)
Global("A7Quest5","GLOBAL",0)
Global("A7Q5AfaaqAppears","GLOBAL",0)
Global("A7AfaaqEnslaved","GLOBAL",0)
Global("A7AfaaqSummoned","GLOBAL",1)
PartyHasItem("A7DJLMPA") // Djinni lamp
!Global("Enclave","GLOBAL",2)
THEN
RESPONSE #100
SetGlobal("A7Q5Intro","AR5504",1)
CreateCreature("A7Karim",[481.920],E) // Karim
ActionOverride("A7Karim",FaceObject("AMCARRAS"))
ActionOverride("A7Karim",DestroyItem("A7RING01")) // Sandthief's Ring
CreateCreature("A7Q5DJ01",[518.830],SE) // Djinni
ActionOverride("A7Q5DJ01",SetDialog("A7Q5DJ01"))
ActionOverride("A7Q5DJ01",FaceObject("AMCARRAS"))
ActionOverride("A7Q5DJ01",DestroyItem("A7RING01")) // Sandthief's Ring
CreateCreature("A7Q5DJ05",[424.850],SEE) // Djinni
ActionOverride("A7Q5DJ05",SetDialog("A7Q5DJ05"))
ActionOverride("A7Q5DJ05",FaceObject("AMCARRAS"))
ActionOverride("A7Q5DJ05",DestroyItem("A7RING01")) // Sandthief's Ring
ActionOverride("AMCARRAS",FaceObject("A7Karim"))
Wait(2)
ActionOverride("A7Karim",StartDialogueNoSet("AMCARRAS"))
END
IF
Global("A7Q5Intro","AR5504",0)
Global("A7Quest5","GLOBAL",0)
Global("A7Q5AfaaqAppears","GLOBAL",0)
Global("A7AfaaqEnslaved","GLOBAL",1)
OR(2)
PartyHasItem("A7DJLMP") // Djinni lamp
PartyHasItem("A7DJLMPA") // Djinni lamp
!Global("Enclave","GLOBAL",2)
THEN
RESPONSE #100
SetGlobal("A7Q5Intro","AR5504",1)
CreateCreature("A7Karim",[481.920],E) // Karim
ActionOverride("A7Karim",FaceObject("AMCARRAS"))
ActionOverride("A7Karim",DestroyItem("A7RING01")) // Sandthief's Ring
CreateCreature("A7Q5DJ01",[518.830],SE) // Djinni
ActionOverride("A7Q5DJ01",SetDialog("A7Q5DJ01"))
ActionOverride("A7Q5DJ01",FaceObject("AMCARRAS"))
ActionOverride("A7Q5DJ01",DestroyItem("A7RING01")) // Sandthief's Ring
CreateCreature("A7Q5DJ05",[424.850],SEE) // Djinni
ActionOverride("A7Q5DJ05",SetDialog("A7Q5DJ05"))
ActionOverride("A7Q5DJ05",FaceObject("AMCARRAS"))
ActionOverride("A7Q5DJ05",DestroyItem("A7RING01")) // Sandthief's Ring
ActionOverride("AMCARRAS",FaceObject("A7Karim"))
Wait(2)
ActionOverride("A7Karim",StartDialogueNoSet("AMCARRAS"))
END
IF
Global("A7Q5Intro","AR5504",0)
Global("A7Quest5","GLOBAL",0)
Global("A7Q5AfaaqAppears","GLOBAL",1)
!Global("Enclave","GLOBAL",2)
THEN
RESPONSE #100
SetGlobal("A7Q5Intro","AR5504",1)
SetGlobal("A7Q5AfaaqAppears","GLOBAL",2)
CreateCreature("A7Karim",[481.920],E) // Karim
ActionOverride("A7Karim",FaceObject("AMCARRAS"))
ActionOverride("A7Karim",DestroyItem("A7RING01")) // Sandthief's Ring
CreateCreature("A7Q5DJ01",[518.830],SE) // Djinni
ActionOverride("A7Q5DJ01",SetDialog("A7Q5DJ01"))
ActionOverride("A7Q5DJ01",FaceObject("AMCARRAS"))
ActionOverride("A7Q5DJ01",DestroyItem("A7RING01")) // Sandthief's Ring
CreateCreature("A7Q5DJ05",[424.850],SEE) // Djinni
ActionOverride("A7Q5DJ05",SetDialog("A7Q5DJ05"))
ActionOverride("A7Q5DJ05",FaceObject("AMCARRAS"))
ActionOverride("A7Q5DJ05",DestroyItem("A7RING01")) // Sandthief's Ring
ActionOverride("A7Q5DJ05",SetName(175579)) // Afaaq
ActionOverride("A7Q5DJ05",ApplySpellRES("A7Q5PIC1",Myself)) // No such index
ActionOverride("A7Q5DJ05",SetGlobal("Afaaq","LOCALS",1))
ActionOverride("AMCARRAS",FaceObject("A7Karim"))
Wait(2)
ActionOverride("A7Karim",StartDialogueNoSet("AMCARRAS"))
END
IF
Global("A7Q5Intro","AR5504",0)
THEN
RESPONSE #100
SetGlobal("A7Q5Intro","AR5504",1)
SetGlobal("A7Quest5","GLOBAL",11)
END
IF
GlobalGT("A7Quest5","GLOBAL",0)
GlobalLT("A7Quest5","GLOBAL",10)
Global("A7Q5Permission","GLOBAL",1)
Global("A7Q5Protection","GLOBAL",1)
Global("A7EnablePool","AR5504",0)
THEN
RESPONSE #100
SetGlobal("A7EnablePool","AR5504",1)
TriggerActivation("A7InfoWater_1",FALSE)
TriggerActivation("A7InfoWater_2",TRUE)
END
IF
GlobalGT("A7Quest5","GLOBAL",0)
GlobalLT("A7Quest5","GLOBAL",10)
Global("A7Q5Permission","GLOBAL",1)
Global("A7Q5Protection","GLOBAL",0)
Global("A7EnablePool","AR5504",1)
THEN
RESPONSE #100
SetGlobal("A7EnablePool","AR5504",0)
TriggerActivation("A7InfoWater_2",FALSE)
TriggerActivation("A7InfoWater_1",TRUE)
END
IF
Global("A7Quest5","GLOBAL",10)
Global("A7Finalized","AR5504",0)
THEN
RESPONSE #100
SetGlobal("A7Finalized","AR5504",1)
AmbientActivate("A7Bubbles_1",FALSE)
AmbientActivate("A7Bubbles_2",FALSE)
AmbientActivate("A7Bubbles_3",FALSE)
AmbientActivate("A7Bubbles_4",FALSE)
AmbientActivate("A7Bubbles_5",FALSE)
AmbientActivate("A7Steam_1",FALSE)
AmbientActivate("A7Steam_2",FALSE)
AmbientActivate("A7Steam_3",FALSE)
AmbientActivate("A7Steam_4",FALSE)
AmbientActivate("A7Steam_5",FALSE)
TriggerActivation("A7InfoWater_2",FALSE)
TriggerActivation("A7InfoWater_1",TRUE)
END
IF
OR(2)
Global("Enclave","GLOBAL",2)
Dead("AMCARRAS")
Global("A7Q5Permission","GLOBAL",0)
THEN
RESPONSE #100
SetGlobal("A7Q5Permission","GLOBAL",1)
END
IF
Global("A7Quest5","GLOBAL",0)
GlobalLT("MONKSPAWNEDSMUGGLERPLOT","GLOBAL",3)
THEN
RESPONSE #100
SetGlobal("MONKSPAWNEDSMUGGLERPLOT","GLOBAL",3)
END
IF
GlobalGT("A7Quest5","GLOBAL",1)
Global("MONKSPAWNEDSMUGGLERPLOT","GLOBAL",3)
THEN
RESPONSE #100
SetGlobal("MONKSPAWNEDSMUGGLERPLOT","GLOBAL",0)
END
IF
Global("A7Q5Protection","GLOBAL",1)
!GlobalTimerNotExpired("A7Q5ProtectionWarnTimer","GLOBAL")
!GlobalTimerNotExpired("A7Q5ProtectionTimer","GLOBAL")
THEN
RESPONSE #100
SetGlobal("A7Q5Protection","GLOBAL",0)
SetGlobal("A7Q5ProtectionWarn","GLOBAL",1)
END
IF
!Global("A7Quest5","GLOBAL",10)
RealGlobalTimerExpired("A7Q5TremorTimer","AR5504")
RandomNum(50,1)
THEN
RESPONSE #100
RealSetGlobalTimer("A7Q5TremorTimer","AR5504",TWELVE_MINUTES)
PlaySound("EFF_P92")
ScreenShake([5.5],30)
END
IF
InParty("CVSandr")
Global("PelligFollow","GLOBAL",1)
!InActiveArea("pellig")
!See("pellig")
!Dead("pellig")
THEN
RESPONSE #100
MoveGlobalObject("Pellig","CVSandr")
END
IF
!Allegiance("Pellig",CONTROLLED)
Delay(10)
THEN
RESPONSE #100
ChangeEnemyAlly("Pellig",CONTROLLED)
END
IF
Global("HaiassJumpOn","GLOBAL",1)
Global("HaiassSeUne","GLOBAL",1)
!InActiveArea("haiass")
!See("haiass")
!Dead("haiass")
THEN
RESPONSE #100
MoveGlobalObject("haiass",Protagonist)
END
IF
!Allegiance("haiass",CONTROLLED)
Delay(12)
THEN
RESPONSE #100
ChangeEnemyAlly("haiass",CONTROLLED)
END