eviltotem.lua 655 B

1234567891011121314151617181920212223242526
  1. --[[
  2. Script Name : SpawnScripts/QueensColony/eviltotem.lua
  3. Script Purpose : Handles enabling/disabling the totems on the correct step as well as updates
  4. Script Author : Jabantiz
  5. Script Date : 9/9/2016
  6. Script Notes : <special-instructions>
  7. --]]
  8. local TheSourceOfEvil = 164
  9. function spawn(NPC)
  10. SetRequiredQuest(NPC, TheSourceOfEvil, 2)
  11. end
  12. function respawn(NPC)
  13. spawn(NPC)
  14. end
  15. function casted_on(NPC, Spawn, Message)
  16. if Message == "destroy totem" then
  17. if HasQuest(Spawn, TheSourceOfEvil) and GetQuestStep(Spawn, TheSourceOfEvil) == 2 then
  18. AddStepProgress(Spawn, TheSourceOfEvil, 2, 1)
  19. Despawn(NPC)
  20. end
  21. end
  22. end