9
3

fogcubespell.lua 672 B

1234567891011121314151617181920212223242526272829
  1. --[[
  2. Script Name : SpawnScripts/QueensColony/fogcubespell.lua
  3. Script Author : Premierio015
  4. Script Date : 2020.08.22 06:08:35
  5. Script Purpose :
  6. :
  7. --]]
  8. function spawn(NPC)
  9. SetPlayerProximityFunction(NPC, 15, "InRange", "LeaveRange")
  10. end
  11. function respawn(NPC)
  12. spawn(NPC)
  13. end
  14. function InRange(NPC)
  15. local zone = GetZone(NPC)
  16. local Puppeteer = GetSpawnByLocationID(zone, 430289)
  17. if Puppeteer ~= nil then
  18. PlayAnimation(NPC, 4012)
  19. AddTimer(NPC, 7000, "InRange")
  20. end
  21. end
  22. function LeaveRange(NPC)
  23. PlayAnimation(NPC, 4011)
  24. end