Desia.lua 721 B

1234567891011121314151617181920212223242526272829303132333435
  1. --[[
  2. Script Name : SpawnScripts/Freeport/Desia.lua
  3. Script Author : Premierio015
  4. Script Date : 2020.07.19 10:07:35
  5. Script Purpose :
  6. :
  7. --]]
  8. dofile("SpawnScripts/Generic/GenericGuardVoiceOvers.lua")
  9. function spawn(NPC)
  10. AddTimer(NPC, 700, "followguard", 1, Spawn)
  11. end
  12. function hailed(NPC, Spawn)
  13. FaceTarget(NPC, Spawn)
  14. GenericGuardHail(NPC, Spawn, Faction)
  15. end
  16. function followguard(NPC, Spawn)
  17. local zone = GetZone(NPC)
  18. local leader = GetSpawnByLocationID(zone, 55796)
  19. SetFollowTarget(NPC, leader)
  20. if not IsFollowing(NPC) then
  21. ToggleFollow(NPC)
  22. SetSpeed(NPC, 1.9)
  23. end
  24. end
  25. function respawn(NPC)
  26. spawn(NPC)
  27. end