a_necromancer_totem.lua 540 B

12345678910111213141516171819202122232425
  1. --[[
  2. Script Name : SpawnScripts/FrostfangSea/a_necromancer_totem.lua
  3. Script Purpose : the necromancer totem in frostfang
  4. Script Author : theFoof
  5. Script Date : 2013.8.11
  6. Script Notes :
  7. --]]
  8. local SometimesKnut = 84
  9. function spawn(NPC)
  10. AddSpawnAccess(NPC, NPC)
  11. SetPlayerProximityFunction(NPC, 100, "SpawnAccess", "SpawnAccess")
  12. SpawnSet(NPC, "action_state", "2623")
  13. end
  14. function respawn(NPC)
  15. spawn(NPC)
  16. end
  17. function SpawnAccess(NPC, Spawn)
  18. if GetQuestStep(Spawn, SometimesKnut) == 3 then
  19. AddSpawnAccess(NPC, Spawn)
  20. end
  21. end