Wendy.lua 674 B

12345678910111213141516171819202122232425262728293031
  1. --[[
  2. Script Name : SpawnScripts/Nettleville/Wendy.lua
  3. Script Author : Dorbin
  4. Script Date : 2022.06.23 02:06:11
  5. Script Purpose :
  6. :
  7. --]]
  8. dofile("SpawnScripts/Generic/GenericGuardVoiceOvers.lua")
  9. function spawn(NPC)
  10. SetPlayerProximityFunction(NPC, 7, "InRange", "LeaveRange")
  11. end
  12. function InRange(NPC, Spawn)
  13. CheckFaction(NPC, Spawn, "Qeynos")
  14. if GetFactionAmount(Spawn,11)>0 then
  15. if math.random(1,100)<25 then
  16. GenericGuardHail(NPC, Spawn)
  17. end
  18. end
  19. end
  20. function hailed(NPC, Spawn)
  21. FaceTarget(NPC, Spawn)
  22. GenericGuardHail(NPC, Spawn)
  23. end
  24. function respawn(NPC)
  25. spawn(NPC)
  26. end