9
3

KeeperVaracusTKur.lua 14 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270
  1. --[[
  2. Script Name : SpawnScripts/Graveyard/KeeperVaracusTKur.lua
  3. Script Purpose : Keeper Varacus T'Kur
  4. Script Author : Scatman
  5. Script Date : 2009.07.11
  6. Script Notes :
  7. --]]
  8. local QUEST_1 = 547
  9. local QUEST_2 = 233
  10. local QUEST_5 = 235
  11. function spawn(NPC)
  12. ProvidesQuest(NPC, QUEST_2)
  13. end
  14. function respawn(NPC)
  15. spawn(NPC)
  16. end
  17. function hailed(NPC, Spawn)
  18. FaceTarget(NPC, Spawn)
  19. conversation = CreateConversation()
  20. if HasCompletedQuest(Spawn, QUEST_1) then
  21. if HasCompletedQuest(Spawn, QUEST_2) then
  22. if HasCompletedQuest(Spawn, QUEST_5) then
  23. Say(NPC, "Back again? we have nothing else to offer you!", Spawn)
  24. elseif HasQuest(Spawn, QUEST_5) then
  25. OnQuest5(NPC, Spawn, conversation)
  26. else
  27. Say(NPC, "Thank you for your help!", Spawn)
  28. end
  29. elseif HasQuest(Spawn, QUEST_2) then
  30. OnQuest2(NPC, Spawn, conversation)
  31. else
  32. FindThePages(NPC, Spawn, conversation)
  33. end
  34. elseif HasQuest(Spawn, QUEST_1) then
  35. OnQuest1(NPC, Spawn, conversation)
  36. else
  37. PlayFlavor(NPC, "voiceover/english/tutorial_revamp/keeper_varacus_t_kur/fprt_adv02_graveyard/varacus_tkur_busy_c0efc70b.mp3", "The Keepers of Ethernere don't have time for chatting.", "", 3808851913, 4000050632, Spawn)
  38. end
  39. end
  40. --------------------------------------------------------------------------------------------------------------------------------
  41. -- QUEST 1
  42. --------------------------------------------------------------------------------------------------------------------------------
  43. function OnQuest1(NPC, Spawn, conversation)
  44. PlayFlavor(NPC, "voiceover/english/tutorial_revamp/keeper_varacus_t_kur/fprt_adv02_graveyard/varacus_tkur001.mp3", "", "", 829430571, 4055688593, Spawn)
  45. AddConversationOption(conversation, "Greetings. You must be Varacus.", "dlg_9_1")
  46. AddConversationOption(conversation, "Nothing, I thought you were someone else.")
  47. StartConversation(conversation, NPC, Spawn, "Yes, what is it?")
  48. end
  49. function dlg_9_1(NPC, Spawn)
  50. FaceTarget(NPC, Spawn)
  51. conversation = CreateConversation()
  52. PlayFlavor(NPC, "voiceover/english/tutorial_revamp/keeper_varacus_t_kur/fprt_adv02_graveyard/varacus_tkur002.mp3", "", "", 1358191858, 2542564847, Spawn)
  53. AddConversationOption(conversation, "My name is " .. GetName(Spawn) .. ". Zaddar sent me on behalf of the Academy.", "dlg_9_2")
  54. AddConversationOption(conversation, "None of your business, Teir'Dal.")
  55. StartConversation(conversation, NPC, Spawn, "Well, that all depends. Who are you?")
  56. end
  57. function dlg_9_2(NPC, Spawn)
  58. FaceTarget(NPC, Spawn)
  59. conversation = CreateConversation()
  60. PlayFlavor(NPC, "voiceover/english/tutorial_revamp/keeper_varacus_t_kur/fprt_adv02_graveyard/varacus_tkur003.mp3", "", "", 3292551343, 1126004800, Spawn)
  61. AddConversationOption(conversation, "You don't sound very respectful toward your superior.", "dlg_9_3")
  62. AddConversationOption(conversation, "I must be going.")
  63. StartConversation(conversation, NPC, Spawn, "Zaddar sent you, eh? Far be it from him to get his hands dirty in the Graveyard, I suppose!")
  64. end
  65. function dlg_9_3(NPC, Spawn)
  66. FaceTarget(NPC, Spawn)
  67. conversation = CreateConversation()
  68. PlayFlavor(NPC, "voiceover/english/tutorial_revamp/keeper_varacus_t_kur/fprt_adv02_graveyard/varacus_tkur004.mp3", "", "", 2946582431, 2561170377, Spawn)
  69. AddConversationOption(conversation, "Where does your order's name come from?", "dlg_9_4")
  70. AddConversationOption(conversation, "Interesting, but I must go.")
  71. StartConversation(conversation, NPC, Spawn, "Though we Keepers of Ethernere must answer to the Academy of Arcane Science, ours is a grave responsibility. We watch over the tombs of Norrath and ensure that the spirits of the dead make their journey to the afterlife. You have no doubt seen our guards patrolling the Graveyard roads, and perhaps noticed the boneyard watchers we summon to watch for disturbances.")
  72. end
  73. function dlg_9_4(NPC, Spawn)
  74. FaceTarget(NPC, Spawn)
  75. conversation = CreateConversation()
  76. PlayFlavor(NPC, "voiceover/english/tutorial_revamp/keeper_varacus_t_kur/fprt_adv02_graveyard/varacus_tkur005.mp3", "", "", 668156763, 3742751823, Spawn)
  77. AddConversationOption(conversation, "A fascinating tale, but Zaddar sent me to retrieve some tome pages.", "dlg_9_5")
  78. AddConversationOption(conversation, "I care not for your tale.")
  79. StartConversation(conversation, NPC, Spawn, "The Keepers of Ethernere come from a proud tradition of service to the House of the Dead in our ancient Teir'Dal city of Neriak. Ethernere is a dark realm of agony where spirits of the dead must travel. It is said that when a Norrathian dies, the bell in Deathtoll Tower at the heart of Ethernere rings to signal their spirit's arrival.")
  80. end
  81. function dlg_9_5(NPC, Spawn)
  82. FaceTarget(NPC, Spawn)
  83. conversation = CreateConversation()
  84. PlayFlavor(NPC, "voiceover/english/tutorial_revamp/keeper_varacus_t_kur/fprt_adv02_graveyard/varacus_tkur006.mp3", "", "", 1546096595, 964116993, Spawn)
  85. AddConversationOption(conversation, "The Overlord will not be pleased. He commanded that Zaddar be given the pages.", "FindThePages")
  86. AddConversationOption(conversation, "This task is not my responsibility.")
  87. StartConversation(conversation, NPC, Spawn, "Ah yes, you seek the tome pages. Unfortunately, however, they have gone missing. They may be scattered about the Graveyard, or some might have fallen into the hands of the undead. Such creatures are drawn to objects of arcane power. I have other duties to attend to, so you will need to conduct your own search for the pages here in the Graveyard.")
  88. end
  89. function FindThePages(NPC, Spawn, conversation)
  90. if HasQuest(Spawn, QUEST_1) then
  91. SetStepComplete(Spawn, QUEST_1, 1)
  92. end
  93. if conversation == nil then
  94. FaceTarget(NPC, Spawn)
  95. conversation = CreateConversation()
  96. end
  97. PlayFlavor(NPC, "voiceover/english/tutorial_revamp/keeper_varacus_t_kur/fprt_adv02_graveyard/varacus_tkur007.mp3", "", "", 2021743149, 3486926438, Spawn)
  98. AddConversationOption(conversation, "I will find the pages.", "OfferQuest2")
  99. AddConversationOption(conversation, "I can't help you right now.")
  100. StartConversation(conversation, NPC, Spawn, "I had no idea this matter was so urgent to the Overlord! Please, hero of Freeport, you must find those pages. If not, I think all of us may face our master's wrath. Please let me know when you have found them.")
  101. end
  102. --------------------------------------------------------------------------------------------------------------------------------
  103. -- QUEST 2
  104. --------------------------------------------------------------------------------------------------------------------------------
  105. function OfferQuest2(NPC, Spawn)
  106. FaceTarget(NPC, Spawn)
  107. OfferQuest(NPC, Spawn, QUEST_2)
  108. end
  109. function OnQuest2(NPC, Spawn, conversation)
  110. PlayFlavor(NPC, "voiceover/english/tutorial_revamp/keeper_varacus_t_kur/fprt_adv02_graveyard/varacus_tkur009.mp3", "", "", 3736503585, 3888829392, Spawn)
  111. if GetQuestStep(Spawn, QUEST_2) > 4 then
  112. Say(NPC, "Please, don't tell anyone about our conversation!", Spawn)
  113. else
  114. if GetQuestStep(Spawn, QUEST_2) == 4 then
  115. AddConversationOption(conversation, "I've found the missing pages.", "dlg_10_1")
  116. end
  117. AddConversationOption(conversation, "Not yet, but I will keep looking.")
  118. StartConversation(conversation, NPC, Spawn, "I hope your search for the missing pages has been fruitful. Neither of us can afford to disappoint the Overlord.")
  119. end
  120. end
  121. function dlg_10_1(NPC, Spawn)
  122. FaceTarget(NPC, Spawn)
  123. conversation = CreateConversation()
  124. PlayFlavor(NPC, "voiceover/english/tutorial_revamp/keeper_varacus_t_kur/fprt_adv02_graveyard/varacus_tkur010.mp3", "", "", 3933639759, 3329980648, Spawn)
  125. AddConversationOption(conversation, "By the Tower of Marr and near the graves of the fallen knights. Some were also in the possession of the undead.", "dlg_10_2")
  126. AddConversationOption(conversation, "I don't have time to discuss this.")
  127. StartConversation(conversation, NPC, Spawn, "Well done, " .. GetName(Spawn) .. "! Zaddar was right to choose you for this duty. Where did you find the pages?")
  128. end
  129. function dlg_10_2(NPC, Spawn)
  130. FaceTarget(NPC, Spawn)
  131. conversation = CreateConversation()
  132. PlayFlavor(NPC, "voiceover/english/tutorial_revamp/keeper_varacus_t_kur/fprt_adv02_graveyard/varacus_tkur011.mp3", "", "", 3532304049, 948480083, Spawn)
  133. AddConversationOption(conversation, "What could be causing this to happen?", "dlg_10_3")
  134. AddConversationOption(conversation, "This is no concern of mine.")
  135. StartConversation(conversation, NPC, Spawn, "The undead had them, eh? It is as I feared. There has been a marked increase in their activities as of late, the investigation of which has monopolized my time.")
  136. end
  137. function dlg_10_3(NPC, Spawn)
  138. FaceTarget(NPC, Spawn)
  139. conversation = CreateConversation()
  140. PlayFlavor(NPC, "voiceover/english/tutorial_revamp/keeper_varacus_t_kur/fprt_adv02_graveyard/varacus_tkur012.mp3", "", "", 422855190, 220610803, Spawn)
  141. AddConversationOption(conversation, "I will take the pages to him.", "dlg_10_4")
  142. AddConversationOption(conversation, "It's not really my problem.")
  143. StartConversation(conversation, NPC, Spawn, "Perhaps the veil between our world and Ethernere is weakening, or maybe the influence of Mithaniel Marr is returning in some way to awaken his fallen soldiers. In any case, the safety of Freeport demands that you get these pages to Zaddar right away.")
  144. end
  145. function dlg_10_4(NPC, Spawn)
  146. SetStepComplete(Spawn, QUEST_2, 4)
  147. FaceTarget(NPC, Spawn)
  148. conversation = CreateConversation()
  149. PlayFlavor(NPC, "voiceover/english/tutorial_revamp/keeper_varacus_t_kur/fprt_adv02_graveyard/varacus_tkur013.mp3", "", "", 2923473609, 4294205867, Spawn)
  150. AddConversationOption(conversation, "I will do so. I hope to work with you again, Varacus.")
  151. AddConversationOption(conversation, "I'm sick of running errands. Farewell.")
  152. StartConversation(conversation, NPC, Spawn, "Here, take this book cover and put the pages inside it for safe keeping. Take the tome to Zaddar so that he can finish his research.")
  153. end
  154. --------------------------------------------------------------------------------------------------------------------------------
  155. -- QUEST 5
  156. --------------------------------------------------------------------------------------------------------------------------------
  157. function OnQuest5(NPC, Spawn, conversation)
  158. if GetQuestStep(Spawn, QUEST_5) == 1 then
  159. PlayFlavor(NPC, "voiceover/english/tutorial_revamp/keeper_varacus_t_kur/fprt_adv02_graveyard/varacus_tkur015.mp3", "", "", 423371381, 2980925675, Spawn)
  160. AddConversationOption(conversation, "Zaddar has need of something that you possess.", "dlg_13_1")
  161. AddConversationOption(conversation, "Nevermind, I need to go.")
  162. StartConversation(conversation, NPC, Spawn, "Hello again, " .. GetName(Spawn) .. ". What brings you back to the Keepers?")
  163. else
  164. PlayFlavor(NPC, "voiceover/english/tutorial_revamp/keeper_varacus_t_kur/fprt_adv02_graveyard/varacus_tkur_took_staff_4dd499f0.mp3", "Make sure you take care of our staff!", "", 1927300864, 3031979454, Spawn)
  165. end
  166. end
  167. function dlg_13_1(NPC, Spawn)
  168. FaceTarget(NPC, Spawn)
  169. conversation = CreateConversation()
  170. PlayFlavor(NPC, "voiceover/english/tutorial_revamp/keeper_varacus_t_kur/fprt_adv02_graveyard/varacus_tkur016.mp3", "", "", 2481073188, 86162182, Spawn)
  171. AddConversationOption(conversation, "No, he needs the Staff of Ethernere.", "dlg_13_2")
  172. AddConversationOption(conversation, "Nevermind, I need to go.")
  173. StartConversation(conversation, NPC, Spawn, "I have no more spell parchments, if that's what he's after.")
  174. end
  175. function dlg_13_2(NPC, Spawn)
  176. FaceTarget(NPC, Spawn)
  177. conversation = CreateConversation()
  178. PlayFlavor(NPC, "voiceover/english/tutorial_revamp/keeper_varacus_t_kur/fprt_adv02_graveyard/varacus_tkur017.mp3", "", "", 722192907, 1883808749, Spawn)
  179. AddConversationOption(conversation, "But Zaddar says it is critical that he use it.", "dlg_13_3")
  180. AddConversationOption(conversation, "Just forget it.")
  181. StartConversation(conversation, NPC, Spawn, "The Staff of Ethernere is our most sacred relic, entrusted to our order when it was founded in Neriak. I couldn't possibly part with it, even for a short while.")
  182. end
  183. function dlg_13_3(NPC, Spawn)
  184. FaceTarget(NPC, Spawn)
  185. conversation = CreateConversation()
  186. PlayFlavor(NPC, "voiceover/english/tutorial_revamp/keeper_varacus_t_kur/fprt_adv02_graveyard/varacus_tkur018.mp3", "", "", 821574395, 1723573145, Spawn)
  187. AddConversationOption(conversation, "The ward keeping the undead inside the Graveyard is failing, and we need the staff to restore it.", "dlg_13_4")
  188. AddConversationOption(conversation, "Go ask him yourself.")
  189. StartConversation(conversation, NPC, Spawn, "Though my order now serves the Academy of Arcane Science, my vow to the Keepers of Ethernere supersedes the Academy's demands. Why does he need the staff?")
  190. end
  191. function dlg_13_4(NPC, Spawn)
  192. FaceTarget(NPC, Spawn)
  193. conversation = CreateConversation()
  194. PlayFlavor(NPC, "voiceover/english/tutorial_revamp/keeper_varacus_t_kur/fprt_adv02_graveyard/varacus_tkur019.mp3", "", "", 3925056079, 4036271614, Spawn)
  195. AddConversationOption(conversation, "There's no time, Varacus. We must do this ourselves.", "dlg_13_5")
  196. AddConversationOption(conversation, "You're probably right.")
  197. StartConversation(conversation, NPC, Spawn, "That is dire news indeed! But wouldn't someone like Thaumaturge Ranollious at the Academy be better suited for this task?")
  198. end
  199. function dlg_13_5(NPC, Spawn)
  200. FaceTarget(NPC, Spawn)
  201. conversation = CreateConversation()
  202. PlayFlavor(NPC, "voiceover/english/tutorial_revamp/keeper_varacus_t_kur/fprt_adv02_graveyard/varacus_tkur020.mp3", "", "", 2024157770, 1751672495, Spawn)
  203. AddConversationOption(conversation, "I'll let him know.", "dlg_13_6")
  204. AddConversationOption(conversation, "Nevermind.")
  205. StartConversation(conversation, NPC, Spawn, "Very well. Zaddar may use the Staff of Ethernere. He can return it to me when he's certain the binding ward is back in place.")
  206. end
  207. function dlg_13_6(NPC, Spawn)
  208. SetStepComplete(Spawn, QUEST_5, 1)
  209. FaceTarget(NPC, Spawn)
  210. conversation = CreateConversation()
  211. -- The Staff of Ethernere
  212. -- TODO: Show quest reward popup.
  213. if not HasItem(Spawn, 21591) then
  214. SummonItem(Spawn, 21591)
  215. end
  216. PlayFlavor(NPC, "voiceover/english/tutorial_revamp/keeper_varacus_t_kur/fprt_adv02_graveyard/varacus_tkur021.mp3", "", "", 1322632030, 1536532403, Spawn)
  217. AddConversationOption(conversation, "I will take good care of the staff, Varacus. Be well.")
  218. StartConversation(conversation, NPC, Spawn, "Travel swiftly, Conjura. All of Freeport is depending on you now!")
  219. end