1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556 |
- --[[
- Script Name : SpawnScripts/WayfarersRest/asuspiciousbarrelFALSE.lua
- Script Author : Dorbin
- Script Date : 2023.09.23 02:09:56
- Script Purpose :
- :
- --]]
- function spawn(NPC)
- end
- function casted_on(NPC, Spawn, Message)
- local zone = GetZone(NPC)
- local Crate = (GetSpawnByLocationID(zone,133786871))
- local Barrel = (GetSpawnByLocationID(zone,133786872))
- if Message == "Inspect" then
- if Crate ~= nil then
- PlayFlavor(Crate,"","","result_dispell1_out",0,0)
- AddTimer(Crate,1500,"Despawning")
- end
- if Barrel ~= nil then
- PlayFlavor(Barrel,"","","result_dispell1_out",0,0)
- AddTimer(Barrel,1500,"Despawning")
- end
- if NPC ~= nil then
- PlayFlavor(NPC,"","","result_dispell1_out",0,0)
- AddTimer(NPC,1500,"Despawning")
- end
- end
- end
- function Despawning(NPC,Spawn)
- local zone = GetZone(NPC)
- local Crate = (GetSpawnByLocationID(zone,133786871))
- local Barrel = (GetSpawnByLocationID(zone,133786872))
- local Wall = (GetSpawnByLocationID(zone,133786875))
- if Crate ~= nil then
- Despawn(Crate)
- end
- if Barrel ~= nil then
- Despawn(Barrel)
- end
- if NPC ~= nil then
- Despawn(NPC)
- if Wall ~= nil then
- Despawn(Wall)
- end
- end
- end
- function respawn(NPC)
- spawn(NPC)
- end
|