spawnInfiltratorKath.lua 1018 B

12345678910111213141516171819202122232425262728293031323334353637383940
  1. --[[
  2. Script Name : SpawnScripts/Freeport/spawnInfiltratorKath.lua
  3. Script Author : cynnar
  4. Script Date : 2023.04.30 01:04:37
  5. Script Purpose :
  6. :
  7. --]]
  8. local QuellingTheRebellion = 5807
  9. function spawn(NPC)
  10. SetPlayerProximityFunction(NPC, 10, "InRange", "LeaveRange", Spawn)
  11. end
  12. function respawn(NPC)
  13. spawn(NPC)
  14. end
  15. function InRange(NPC, Spawn)
  16. AddTimer(NPC, 3000, "SpawnKath", 1, Spawn)
  17. end
  18. function LeaveRange(NPC, Spawn)
  19. end
  20. function SpawnKath(NPC, Spawn)
  21. local zone = GetZone(Spawn)
  22. if HasQuest(Spawn, QuellingTheRebellion) then
  23. if GetQuestStep(Spawn, QuellingTheRebellion) == 3 then
  24. if GetSpawnByLocationID(zone, 133784675) == nil then
  25. Say(NPC, "You are currently on step " .. GetQuestStep(Spawn, QuellingTheRebellion))
  26. local InfiltratorKath = SpawnMob(zone, 5590963, false, -99.12, -11.00, -76.83, 362.84)
  27. end
  28. end
  29. end
  30. end