the_spirits_release.lua 2.1 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556
  1. --[[
  2. Script Name : the_spirits_release.lua
  3. Script Purpose : Handles the quest, "The Spirit's Release"
  4. Script Author : EmemJR
  5. Script Date : 10/7/2019
  6. Script Notes : Auto generated with QuestParser.
  7. Zone : Thieves' Way
  8. Quest Giver : item A mystical Sphere(id# 2304
  9. Preceded by : None
  10. Followed by : None
  11. --]]
  12. local itemId = 2304
  13. function Init(Quest)
  14. AddQuestStepKill(Quest, 1, "I must kill some netherot chanters.", 5, 100, "I must kill five netherot chanters.", 611, 1540015)
  15. AddQuestStepCompleteAction(Quest, 1, "Step1Complete")
  16. end
  17. function Accepted(Quest, QuestGiver, Player)
  18. -- Add dialog here for when the quest is accepted
  19. end
  20. function Declined(Quest, QuestGiver, Player)
  21. -- Add dialog here for when the quest is declined
  22. end
  23. function Deleted(Quest, QuestGiver, Player)
  24. -- Remove any quest specific items here when the quest is deleted
  25. end
  26. function Step1Complete(Quest, QuestGiver, Player)
  27. UpdateQuestStepDescription(Quest, 1, "I have killed some netherot chanters.")
  28. UpdateQuestTaskGroupDescription(Quest, 1, "I have killed five netherot chanters")
  29. AddQuestStep(Quest, 2, "I should inspect the orb.", 1, 100, "I should inspect the orb.", 11)
  30. AddQuestStepCompleteAction(Quest, 2, "QuestComplete")
  31. end
  32. function QuestComplete(Quest, QuestGiver, Player)
  33. -- The following UpdateQuestStepDescription and UpdateTaskGroupDescription are not needed, parser adds them for completion in case stuff needs to be moved around
  34. UpdateQuestStepDescription(Quest, 2, "I have inspected the orb.")
  35. UpdateQuestTaskGroupDescription(Quest, 2, "I have inspected the orb.")
  36. RemoveItem(Player, itemId)
  37. UpdateQuestDescription(Quest, "I found a magic stone that contained the spirit of a former Darkblade rogue. The spirit was freed when I killed the Netherot Chanters. The power of the stone is now mine.")
  38. GiveQuestReward(Quest, Player)
  39. end
  40. function Reload(Quest, QuestGiver, Player, Step)
  41. if Step == 1 then
  42. Step1Complete(Quest, QuestGiver, Player)
  43. elseif Step == 2 then
  44. QuestComplete(Quest, QuestGiver, Player)
  45. end
  46. end