acryptrobber.lua 855 B

12345678910111213141516171819202122232425262728293031323334353637383940
  1. --[[
  2. Script Name : SpawnScripts/The Sepulcher of Jahnda/acryptrobber.lua
  3. Script Author : Premierio015
  4. Script Date : 2021.10.22 07:10:18
  5. Script Purpose :
  6. :
  7. --]]
  8. function hailed(NPC, Spawn)
  9. FaceTarget(NPC, Spawn)
  10. end
  11. function spawn(NPC)
  12. AddSpawnAccess(NPC, NPC)
  13. SetPlayerProximityFunction(NPC, 10, "SpawnAccess", "SpawnAccess")
  14. end
  15. function SpawnAccess(NPC, Spawn)
  16. if GetTempVariable(Spawn, "MobAccess") == "true" then
  17. AddSpawnAccess(NPC, Spawn)
  18. SpawnSet(NPC, "faction", 1)
  19. else
  20. RemoveSpawnAccess(NPC, Spawn)
  21. end
  22. end
  23. function death(NPC, Spawn)
  24. local group = GetSpawnByGroupID(zone, 1049684)
  25. if not IsAlive(group) then
  26. local zone = GetZone(NPC)
  27. local LordTonmerk = SpawnByLocationID(zone, LordTonmerkID)
  28. end
  29. end
  30. function respawn(NPC)
  31. spawn(NPC)
  32. end