priest_training_pt_ii_.lua 5.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111
  1. --[[
  2. Script Name : Quests/Hallmark/priest_training_pt_ii_.lua
  3. Script Author : Dorbin
  4. Script Date : 2022.11.19 05:11:41
  5. Script Purpose :
  6. Zone : Hallmark
  7. Quest Giver: Heirophant Aldalad
  8. Preceded by: Priest Training, pt I
  9. Followed by:
  10. --]]
  11. require "SpawnScripts/Generic/DialogModule"
  12. function Init(Quest)
  13. AddQuestStepKill(Quest, 1, "I must kill five toxic bog slugs in the Peat Bog.", 5, 100, "Aldalad has directed me to the Bog to help whittle down five bog slugs.", 611, 8290031 )
  14. AddQuestStepCompleteAction(Quest, 1, "Step1Complete")
  15. end
  16. function Accepted(Quest, QuestGiver, Player)
  17. FaceTarget(QuestGiver, Player)
  18. Dialog.New(QuestGiver, Player)
  19. Dialog.AddDialog("Druids assist in maintaining the Balance. When harmony has been breached, the druid can tell instantly. For example, if you travel to the Bog, you will find that some creatures are thriving at the expense of all others. It is out of balance. If you wish to help the druids in their work, go to the Bog and slay five Carnivorous Slugs.")
  20. Dialog.AddVoiceover("voiceover/english/hierophant_aldalad/qey_north/hierophant_aldalad015.mp3", 3124149580, 1197890726)
  21. PlayFlavor(QuestGiver, "", "", "thanks", 0, 0, Player)
  22. Dialog.AddOption("Ah, I knew you had a task for me! All right. I'll return when I've killed five carnivorous slugs.")
  23. Dialog.Start()
  24. if GetQuestStep(Player,5879)==1 then
  25. SetStepComplete(Player,5879,1)
  26. end
  27. end
  28. function Declined(Quest, QuestGiver, Player)
  29. -- Add dialog here for when the quest is declined
  30. end
  31. function Deleted(Quest, QuestGiver, Player)
  32. -- Remove any quest specific items here when the quest is deleted
  33. end
  34. function Step1Complete(Quest, QuestGiver, Player)
  35. UpdateQuestStepDescription(Quest, 1, "I have killed five toxic bog slugs.")
  36. UpdateQuestTaskGroupDescription(Quest, 1, "I've killed five bog slugs. Hopefully this will help to balance the bog's population.")
  37. AddQuestStepChat(Quest, 2, "I need to speak with Aldalad", 1, "I should let Aldalad know that the slugs' numbers have been reduced", 11, 2220484)
  38. AddQuestStepCompleteAction(Quest, 2, "Step2Complete")
  39. end
  40. function Step2Complete(Quest, QuestGiver, Player)
  41. UpdateQuestStepDescription(Quest, 2, "I've spoken with Aldalad")
  42. UpdateQuestTaskGroupDescription(Quest, 2, "Aldalad has commended me for helping take part of nature's cycles")
  43. AddQuestStepChat(Quest, 3, "I need to help the soldier Homrie near the Claymore in Antonica.", 1, "Aldalad has charged me with helping the Qeynosian soldiers outside of the city", 11, 120411)
  44. AddQuestStepChat(Quest, 4, "I need to help the soldier Selennia near the two southern guard towers in Antonica.", 1, "Aldalad has charged me with helping the Qeynosian soldiers outside of the city", 11, 120269,121378 )
  45. AddQuestStepChat(Quest, 5, "I need to help the soldier Pellenos near the two southern guard towers in Antonica.", 1, "Aldalad has charged me with helping the Qeynosian soldiers outside of the city", 11, 120276,121385)
  46. AddQuestStepCompleteAction(Quest, 3, "Step3Complete")
  47. AddQuestStepCompleteAction(Quest, 4, "Step4Complete")
  48. AddQuestStepCompleteAction(Quest, 5, "Step5Complete")
  49. end
  50. function Step3Complete(Quest, QuestGiver, Player)
  51. UpdateQuestStepDescription(Quest, 3, "I've cured Homrie of poison.")
  52. QuestCheck(Quest, QuestGiver, Player)
  53. end
  54. function Step4Complete(Quest, QuestGiver, Player)
  55. UpdateQuestStepDescription(Quest, 4, "I've saved the life of Selennia.")
  56. QuestCheck(Quest, QuestGiver, Player)
  57. end
  58. function Step5Complete(Quest, QuestGiver, Player)
  59. UpdateQuestStepDescription(Quest, 5, "I've helped to heal the mental wounds of Pellenos.")
  60. QuestCheck(Quest, QuestGiver, Player)
  61. end
  62. function QuestCheck(Quest, QuestGiver, Player)
  63. if QuestStepIsComplete(Player,5773,3) and QuestStepIsComplete(Player,5773,4) and QuestStepIsComplete(Player,5773,5) then
  64. UpdateQuestTaskGroupDescription(Quest, 3, "I've healed the soldiers, but should report to Aldalad as to what befell them")
  65. AddQuestStepChat(Quest, 6, "I need to speak with Aldalad", 1, "I need to report to Aldalad at once", 11, 2220484)
  66. AddQuestStepCompleteAction(Quest, 6, "QuestComplete")
  67. end
  68. end
  69. function QuestComplete(Quest, QuestGiver, Player)
  70. -- The following UpdateQuestStepDescription and UpdateTaskGroupDescription are not needed, parser adds them for completion in case stuff needs to be moved around
  71. UpdateQuestStepDescription(Quest, 6, "I've spoken with Aldalad")
  72. UpdateQuestTaskGroupDescription(Quest, 4, "Aldalad told me all that he can and suggested I make a spiritual choice.")
  73. UpdateQuestDescription(Quest, "I have listened to all that the Hierophant has to offer. Looking in my heart, I know that there is only one way for me to proceed. From hereon, I will follow my chosen path to spirituality and never waver from where it leads me.")
  74. GiveQuestReward(Quest, Player)
  75. end
  76. function Reload(Quest, QuestGiver, Player, Step)
  77. if Step == 1 then
  78. Step1Complete(Quest, QuestGiver, Player)
  79. elseif Step == 2 then
  80. Step2Complete(Quest, QuestGiver, Player)
  81. elseif Step == 3 then
  82. Step3Complete(Quest, QuestGiver, Player)
  83. elseif Step == 4 then
  84. Step4Complete(Quest, QuestGiver, Player)
  85. elseif Step == 5 then
  86. Step5Complete(Quest, QuestGiver, Player)
  87. elseif Step == 6 then
  88. QuestComplete(Quest, QuestGiver, Player)
  89. end
  90. end