9
3

qst_shaman_spawner_skull.lua 1.1 KB

1234567891011121314151617181920212223242526272829303132333435363738394041
  1. --[[
  2. Script Name : SpawnScripts/Caves/qst_shaman_spawner_skull.lua
  3. Script Purpose : qst_shaman_spawner_skull
  4. Script Author : Scatman
  5. Script Date : 2009.10.18
  6. Script Notes :
  7. --]]
  8. local QUEST4_FROM_CONSULBREE = 230
  9. function spawn(NPC)
  10. SetRequiredQuest(NPC, QUEST4_FROM_CONSULBREE, 1)
  11. end
  12. function respawn(NPC)
  13. spawn(NPC)
  14. end
  15. function hailed(NPC, Spawn)
  16. end
  17. function casted_on(Target, Caster)
  18. if HasQuest(Caster, QUEST4_FROM_CONSULBREE) and GetQuestStep(Caster, QUEST4_FROM_CONSULBREE) == 1 then
  19. if HasItem(Caster, 11850) then
  20. local SpearedSkeleton = SpawnMob(GetZone(Caster), 1970139, false, 25.0848, 13.4502, -107.594, 178.328)
  21. SendMessage(Caster, "The skull seems to come alive as a wave of heat blows in from the north.")
  22. -- summoning staff
  23. while HasItem(Caster, 11850) do
  24. RemoveItem(Caster, 11850)
  25. end
  26. local ZenDurath = GetSpawn(Caster, 1970075)
  27. if ZenDurath == nil then
  28. ZenDurath = SpawnMob(GetZone(Caster), 1970075, false, 28.9003, 20.2769, -128.765, 0)
  29. end
  30. Despawn(SpearedSkeleton, 60000)
  31. Despawn(ZenDurath, 60000)
  32. else
  33. SendMessage(Caster, "You need the summoning staff from Consul Bree.")
  34. end
  35. end
  36. end