the_scholars_search.lua 7.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125
  1. --[[
  2. Script Name : Quests/NorthQeynos/the_scholars_search.lua
  3. Script Author : Dorbin
  4. Script Date : 2022.05.15 02:05:01
  5. Script Purpose :
  6. Zone : NorthQeynos
  7. Quest Giver: Scholar Demini
  8. Preceded by: The Age of Rediscovery
  9. Followed by: Never Judge a Book by it's Cover
  10. --]]
  11. require "SpawnScripts/Generic/DialogModule"
  12. function Init(Quest)
  13. AddQuestStepZoneLoc(Quest, 1, "I need to find and search the area around the Bells of Vhalen.", 7, "According to Demini, the scholar to the Sage of Ages was last seen at the Bells of Vhalen out in Antonica. Perhaps I can find him there.", 11, -1300, 38 ,45,12)
  14. AddQuestStepCompleteAction(Quest, 1, "Step1Complete")
  15. UpdateQuestZone(Quest,"Antonica")
  16. end
  17. function Accepted(Quest, QuestGiver, Player)
  18. FaceTarget(QuestGiver, Player)
  19. PlayFlavor(QuestGiver,"","","nod",0,0,Player)
  20. Dialog.New(QuestGiver, Player)
  21. Dialog.AddDialog("I'm hoping you can find the scholar. According to the last page of this journal, he was camping near the Bells of Vhalen. If I remember correctly, that's in Antonica. Maybe you can find a clue as to his whereabouts?")
  22. Dialog.AddOption("I think I can do that. I'll be back when I find out more information.")
  23. Dialog.Start()
  24. end
  25. function Declined(Quest, QuestGiver, Player)
  26. -- Add dialog here for when the quest is declined
  27. end
  28. function Deleted(Quest, QuestGiver, Player)
  29. -- Remove any quest specific items here when the quest is deleted
  30. end
  31. function Step1Complete(Quest, QuestGiver, Player)
  32. UpdateQuestStepDescription(Quest, 1, "I've searched the Bells of Vhalen, but found no trace of the wandering scholar.")
  33. UpdateQuestTaskGroupDescription(Quest, 1, "I didn't find the scholar at the Bells, but I found a number of badger tracks around the area. Maybe that's a clue as to where he can be found.")
  34. AddQuestStepKill(Quest, 2, "I need to kill the grizzled badgers until I find a clue to the scholar's whereabouts.", 1, 66, "I should see if any of the badgers possess any clue as to where the scholar might be found.", 75, 120014, 121194)
  35. AddQuestStepCompleteAction(Quest, 2, "Step2Complete")
  36. end
  37. function Step2Complete(Quest, QuestGiver, Player)
  38. UpdateQuestStepDescription(Quest, 2, "I've found a partially eaten page from a journal.")
  39. UpdateQuestTaskGroupDescription(Quest, 2, "I've found a clue on a badger. It's a page from a journal, claiming that the scholar was actually escorting the Sage of Ages personally. Unfortunately, the last words on the page claim the two had been accosted by bandits.")
  40. AddQuestStepZoneLoc(Quest, 3, "I need to search the area around the Bramble Woods.", 10, "I should check the surrounding region to see if I can find both the scholar and the Sage of Ages. I hope it's not too late to find them.", 11, -1659, -11, 416,12)
  41. AddQuestStepCompleteAction(Quest, 3, "Step3Complete")
  42. end
  43. function Step3Complete(Quest, QuestGiver, Player)
  44. UpdateQuestStepDescription(Quest, 3, "I've searched the Bramble Woods, but found no trace of the pair.")
  45. AddQuestStepZoneLoc(Quest, 4, "I need to search the area around the Qeynos Highway", 15, "I should check the surrounding region to see if I can find both the scholar and the Sage of Ages. I hope it's not too late to find them.", 11,-1723, -14, 376,12)
  46. AddQuestStepCompleteAction(Quest, 4, "Step4Complete")
  47. end
  48. function Step4Complete(Quest, QuestGiver, Player)
  49. UpdateQuestStepDescription(Quest, 4, "I've searched the Qeynos Highway, but found no trace of the pair")
  50. AddQuestStepZoneLoc(Quest, 5, "I need to search the area around the Northern Farmlands", 15, "I should check the surrounding region to see if I can find both the scholar and the Sage of Ages. I hope it's not too late to find them.", 11, -1902, -14, 42,12)
  51. AddQuestStepCompleteAction(Quest, 5, "Step5Complete")
  52. end
  53. function Step5Complete(Quest, QuestGiver, Player)
  54. UpdateQuestStepDescription(Quest, 5, "I've searched the Northern Farmlands, but found no trace of the pair")
  55. AddQuestStepZoneLoc(Quest, 6, "I need to search the area around the Gnollslayer Highlands", 15, "I should check the surrounding region to see if I can find both the scholar and the Sage of Ages. I hope it's not too late to find them.", 11, -1755, -14, 521,12)
  56. AddQuestStepCompleteAction(Quest, 6, "Step6Complete")
  57. end
  58. function Step6Complete(Quest, QuestGiver, Player)
  59. UpdateQuestStepDescription(Quest, 6, "I've searched the Gnollslayer Highlands, but found no trace of the pair")
  60. AddQuestStepZoneLoc(Quest, 7, "I need to search the area around the Scarecrow Fields", 15, "I should check the surrounding region to see if I can find both the scholar and the Sage of Ages. I hope it's not too late to find them.", 11,-1755, -14, 521,12)
  61. AddQuestStepCompleteAction(Quest, 7, "Step7Complete")
  62. end
  63. function Step7Complete(Quest, QuestGiver, Player)
  64. UpdateQuestStepDescription(Quest, 7, "I've searched the Scarecrow Fields, but found no trace of the pair")
  65. AddQuestStepZoneLoc(Quest, 8, "I need to search the area around the Keep of the Gnollslayers", 10, "I should check the surrounding region to see if I can find both the scholar and the Sage of Ages. I hope it's not too late to find them.", 11, -2089, -45, 474,12)
  66. AddQuestStepCompleteAction(Quest, 8, "Step8Complete")
  67. end
  68. function Step8Complete(Quest, QuestGiver, Player)
  69. UpdateQuestStepDescription(Quest, 8, "I've searched the Keep of the Gnollslayers, but found no trace of the pair")
  70. UpdateQuestTaskGroupDescription(Quest, 3, "I found no trace of either the scholar or the Sage of Ages. It seems that the bandits have done away with them.")
  71. UpdateQuestZone(Quest,"North Qeynos")
  72. AddQuestStepChat(Quest, 9, "I need to speak to Demini in North Qeynos.", 1, "I should bring these pages back to Demini for my reward that he promised me.", 11, 2220086)
  73. AddQuestStepCompleteAction(Quest, 9, "QuestComplete")
  74. end
  75. function QuestComplete(Quest, QuestGiver, Player)
  76. -- The following UpdateQuestStepDescription and UpdateTaskGroupDescription are not needed, parser adds them for completion in case stuff needs to be moved around
  77. UpdateQuestStepDescription(Quest, 9, "I've spoken with Demini.")
  78. UpdateQuestTaskGroupDescription(Quest, 4, "I've given the pages of the journal to Demini in exchange for a nice reward.")
  79. UpdateQuestDescription(Quest, "I've given Demini the bad news that the scholar he was searching for had met a bad fate at the hands of some bandits.")
  80. GiveQuestReward(Quest, Player)
  81. end
  82. function Reload(Quest, QuestGiver, Player, Step)
  83. if Step == 1 then
  84. Step1Complete(Quest, QuestGiver, Player)
  85. elseif Step == 2 then
  86. Step2Complete(Quest, QuestGiver, Player)
  87. elseif Step == 3 then
  88. Step3Complete(Quest, QuestGiver, Player)
  89. elseif Step == 4 then
  90. Step4Complete(Quest, QuestGiver, Player)
  91. elseif Step == 5 then
  92. Step5Complete(Quest, QuestGiver, Player)
  93. elseif Step == 6 then
  94. Step6Complete(Quest, QuestGiver, Player)
  95. elseif Step == 7 then
  96. Step7Complete(Quest, QuestGiver, Player)
  97. elseif Step == 8 then
  98. Step8Complete(Quest, QuestGiver, Player)
  99. elseif Step == 9 then
  100. QuestComplete(Quest, QuestGiver, Player)
  101. end
  102. end