PriestKelian.lua 15 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285
  1. --[[
  2. Script Name : SpawnScripts/NorthFreeport/PriestKelian.lua
  3. Script Author : Dorbin
  4. Script Date : 2023.10.02 12:10:44
  5. Script Purpose :
  6. :
  7. --]]
  8. require "SpawnScripts/Generic/DialogModule"
  9. local Quest1 = 5906
  10. local Cleric = 5907
  11. local Druid = 5908
  12. local Shaman = 5909
  13. function spawn(NPC)
  14. ProvidesQuest(NPC, Quest1)
  15. ProvidesQuest(NPC, Cleric)
  16. ProvidesQuest(NPC, Druid)
  17. ProvidesQuest(NPC, Shaman)
  18. end
  19. function hailed(NPC, Spawn)
  20. FaceTarget(NPC, Spawn)
  21. Dialog.New(NPC, Spawn)
  22. Dialog.AddDialog("Speak to me if you are one of the faithful. If you are devoid of any spiritual guidance, you are lost to me, for I cannot save your soul if you've sold it.")
  23. Dialog.AddVoiceover("voiceover/english/priest_kelian/fprt_north/priestkelian000.mp3", 1741103906, 2475357432)
  24. if GetClass(Spawn)== 11 and GetLevel(Spawn)>=7 and not HasQuest(Spawn,Quest1) and not HasCompletedQuest(Spawn,Quest1) then
  25. Dialog.AddOption("I am still possession of my soul and my faith. What can you offer me?","Dialog1")
  26. end
  27. if HasQuest(Spawn,Quest1) and GetQuestStep(Spawn,Quest1)==2 then
  28. Dialog.AddOption("I have stopped the suffering of five Diseased Ratonga by sending them to the sweet embrace of death.","Dialog2")
  29. end
  30. if HasQuest(Spawn,Quest1) and GetQuestStep(Spawn,Quest1)==4 then
  31. Dialog.AddOption("The only foreign plant I was able to find was a purple flower given to me by Annia Kaeso.","Dialog3")
  32. end
  33. if HasQuest(Spawn,Quest1) and GetQuestStep(Spawn,Quest1)==6 then
  34. Dialog.AddOption("I have collected the venom sacs.","Dialog4")
  35. end
  36. if GetQuestStep(Spawn,Cleric)==1 or GetQuestStep(Spawn,Druid)==1 or GetQuestStep(Spawn,Shaman)==1 then
  37. Dialog.AddOption("I am still working to complete my trial. I will return.")
  38. end
  39. if HasCompletedQuest(Spawn,Cleric) or HasCompletedQuest(Spawn,Druid) or HasCompletedQuest(Spawn,Shaman) then
  40. Dialog.AddOption("My soul is still my own thanks to you, Kelian.","Thanks")
  41. else
  42. Dialog.AddOption("My soul is to use as I wish!")
  43. end
  44. if GetLevel(Spawn) >=9 and HasCompletedQuest(Spawn,Quest1) and GetClass(Spawn)==11 and not HasQuest(Spawn, Cleric) and not HasQuest(Spawn, Druid) and not HasQuest(Spawn, Shaman) then
  45. Dialog.AddOption("My soul is ready. What paths lie before me?","FinalClassTest")
  46. end
  47. Dialog.Start()
  48. end
  49. function Thanks(NPC)
  50. FaceTarget(NPC, Spawn)
  51. PlayFlavor(NPC, "", "", "agree", 0, 0, Spawn)
  52. end
  53. function respawn(NPC)
  54. spawn(NPC)
  55. end
  56. function Dialog1(NPC,Spawn)
  57. FaceTarget(NPC, Spawn)
  58. Dialog.New(NPC, Spawn)
  59. Dialog.AddDialog("One of the greatest gifts we possess is the freedom to pursue spiritual enlightenment. You may spend your entire life seeking enlightenment and think you failed, but in your heart you know you succeeded. If you want to continue on this path, then I offer you my guidance.")
  60. Dialog.AddVoiceover("voiceover/english/priest_kelian/fprt_north/priestkelian001.mp3", 3572439854, 118398468)
  61. PlayFlavor(NPC, "", "", "orate", 0, 0, Spawn)
  62. Dialog.AddOption("I must succeed! I will listen to your words for now.","OfferQuest1")
  63. Dialog.AddOption("I don't need 'guidance' from you or anyone else!","Shrug")
  64. Dialog.Start()
  65. end
  66. function Shrug(NPC,Spawn)
  67. PlayFlavor(NPC, "", "", "shrug", 0, 0, Spawn)
  68. end
  69. function OfferQuest1(NPC,Spawn)
  70. OfferQuest(NPC,Spawn,Quest1)
  71. FaceTarget(NPC,Spawn)
  72. end
  73. function Dialog2(NPC,Spawn)
  74. FaceTarget(NPC, Spawn)
  75. Dialog.New(NPC, Spawn)
  76. Dialog.AddDialog("Ahh ... You have a good soul, child. You performed a brave and merciful act down in the sewers. Remember, sometimes death is the only cure, no matter how much it hurts you. Though we couldn't save those poor diseased creatures, we can try to stop the illness from spreading by finding its source.")
  77. Dialog.AddVoiceover("voiceover/english/priest_kelian/fprt_north/priestkelian003.mp3", 597628700, 3290145578)
  78. PlayFlavor(NPC, "", "", "thanks", 0, 0, Spawn)
  79. Dialog.AddOption("Surely the gods will answer for this! Although, I did not see another priest spreading the disease in the sewer...","Dialog2a")
  80. Dialog.Start()
  81. end
  82. function Dialog2a(NPC,Spawn)
  83. FaceTarget(NPC, Spawn)
  84. Dialog.New(NPC, Spawn)
  85. Dialog.AddDialog("Hehehehee ... so innocent, you are. Not all spirituality comes from divine origin, child. The world around us holds power within its soil, plants and rain, which the druids know well. I suspect that the ratongas' disease came from these tempestuous forces. I want you to speak with some merchants in town who may have imported some type of foreign plant. Let me write the list in your journal.")
  86. Dialog.AddVoiceover("voiceover/english/priest_kelian/fprt_north/priestkelian004.mp3", 412624098, 719870239)
  87. PlayFlavor(NPC, "", "", "chuckle", 0, 0, Spawn)
  88. Dialog.AddOption("A plant? I will ask the merchants if someone has been selling such things.","Dialog2b")
  89. Dialog.Start()
  90. end
  91. function Dialog2b(NPC,Spawn)
  92. SetStepComplete(Spawn,Quest1,2)
  93. end
  94. function Dialog3(NPC,Spawn)
  95. FaceTarget(NPC, Spawn)
  96. Dialog.New(NPC, Spawn)
  97. Dialog.AddDialog("Let me see those flowers ... ahh ... yes, I'm familiar with this blossom. No, this didn't cause the ratongas' disease. This flower makes people happy through its odd... errr... appearance. I thought about what we can do for the diseased ratonga in the sewers. I think I have a solution. Are you ready for the rest of your guidance?")
  98. Dialog.AddVoiceover("voiceover/english/priest_kelian/fprt_north/priestkelian005.mp3", 3413963093, 236391412)
  99. PlayFlavor(NPC, "", "", "happy", 0, 0, Spawn)
  100. Dialog.AddOption("So if not the plant, what else could I do about the disease?","Dialog3a")
  101. Dialog.Start()
  102. end
  103. function Dialog3a(NPC,Spawn)
  104. SetStepComplete(Spawn,Quest1,4)
  105. FaceTarget(NPC, Spawn)
  106. Dialog.New(NPC, Spawn)
  107. Dialog.AddDialog("The last path is that of the shaman. The shaman forsakes both the divine and the natural and looks to the spirits surrounding us. You must go to the Sprawl and find the Gravel Vipers that reside there. Let the spirits guide you to the asps with the most poisonous venom.")
  108. Dialog.AddVoiceover("voiceover/english/priest_kelian/fprt_north/priestkelian006.mp3", 3929146556, 1034072743)
  109. PlayFlavor(NPC, "", "", "ponder", 0, 0, Spawn)
  110. Dialog.AddOption("As you wish.")
  111. Dialog.Start()
  112. end
  113. function Dialog4(NPC,Spawn)
  114. FaceTarget(NPC, Spawn)
  115. Dialog.New(NPC, Spawn)
  116. Dialog.AddDialog("Good, good. Hopefully an alchemist can recreate this poison in quantities large enough to fill the water in the sewers below. The ratongas' disease will no longer threaten the citizens of Freeport. As for you, my eager child, I cannot guide your spiritual development much further. It is time for you to decide what path moves your soul.")
  117. Dialog.AddVoiceover("voiceover/english/priest_kelian/fprt_north/priestkelian007.mp3", 2544827648, 3067664425)
  118. PlayFlavor(NPC, "", "", "agree", 0, 0, Spawn)
  119. Dialog.AddOption("I'm glad the ratongas' fate is decided, but my soul is still needs direction.","FinalClassTest")
  120. Dialog.Start()
  121. SetStepComplete(Spawn,Quest1,6)
  122. end
  123. --CLASS QUESTS
  124. function FinalClassTest(NPC,Spawn)
  125. FaceTarget(NPC, Spawn)
  126. Dialog.New(NPC, Spawn)
  127. Dialog.AddDialog("What shall it be? Do you believe in the gods? Perhaps the forces of nature move your soul, or do you feel the pull of the spirit world?")
  128. Dialog.AddVoiceover("voiceover/english/priest_kelian/fprt_north/priestkelian008.mp3", 3156932879, 525367195)
  129. PlayFlavor(NPC, "", "", "nod", 0, 0, Spawn)
  130. Dialog.AddOption("I have faith in the gods. I believe I am a Cleric.","Cleric1")
  131. Dialog.AddOption("I realize now that my calling is to the forces of nature. I think I'm a Druid!","Druid1")
  132. Dialog.AddOption("The spirits speak to me and tell me that my destiny lies in being a Shaman. ","Shaman1")
  133. Dialog.Start()
  134. end
  135. --CLERIC
  136. function Cleric1(NPC,Spawn)
  137. FaceTarget(NPC, Spawn)
  138. Dialog.New(NPC, Spawn)
  139. Dialog.AddDialog("Clerics devote themselves to a god and give their life and soul to that deity. In return for this small sacrifice, the divine force provides a touch of its powers. Only those who believe that the gods are still with us should take this route, for an apathetic believer believes in an apathetic god. Do you have faith in the gods?")
  140. Dialog.AddVoiceover("voiceover/english/priest_kelian/fprt_north/priestkelian009.mp3", 1397579314, 3728059728)
  141. PlayFlavor(NPC, "", "", "orate", 0, 0, Spawn)
  142. Dialog.AddOption("With the help of the gods, I accept. There is nothing I cannot do as long as they are with me. I shall become a cleric.","OfferCleric" )
  143. Dialog.AddOption("What were my options again?","FinalClassTest" )
  144. Dialog.Start()
  145. end
  146. function OfferCleric(NPC,Spawn)
  147. OfferQuest(NPC,Spawn,Cleric)
  148. FaceTarget(NPC,Spawn)
  149. end
  150. function ClericAccept(NPC,Spawn)
  151. FaceTarget(NPC, Spawn)
  152. Dialog.New(NPC, Spawn)
  153. Dialog.AddDialog("Then I will facilitate a prayer trance for you. You will experience a struggle unlike any you've known before... but upon exiting the trance, should you prove successful, you will emerge with the emotional strength to survive and prosper in the re-forged Norrath. Are you ready?")
  154. --Dialog.AddVoiceover("voiceover/english/hierophant_aldalad/qey_north/hierophant_aldalad017.mp3", 2729819197, 1238324646) WE DON"T HAVE THE VO FOR THIS
  155. PlayFlavor(NPC, "", "", "nod", 0, 0, Spawn)
  156. Dialog.AddOption("I am.","ClericPort" )
  157. Dialog.AddOption("I will be shortly. I will return.")
  158. Dialog.Start()
  159. end
  160. function ClericFail(NPC,Spawn)
  161. FaceTarget(NPC, Spawn)
  162. Dialog.New(NPC, Spawn)
  163. Dialog.AddDialog("Though you were not successful in your previous attempt, one of the most valuable lessons an aspiring cleric can learn is perseverance. Are you ready to attempt the trial again?")
  164. --Dialog.AddVoiceover("voiceover/english/hierophant_aldalad/qey_north/hierophant_aldalad017.mp3", 2729819197, 1238324646) WE DON"T HAVE THE VO FOR THIS
  165. PlayFlavor(NPC, "", "", "ponder", 0, 0, Spawn)
  166. Dialog.AddOption("Yes, Aldalad, I am.","ClericPort" )
  167. Dialog.AddOption("I will be shortly. I will return.")
  168. Dialog.Start()
  169. end
  170. function ClericPort(NPC,Spawn)
  171. Trial = GetZone("TheDisconcertingMeditation")
  172. Zone(Trial,Spawn,-47.02, -45.79, -49.3, 272)
  173. end
  174. --DRUID
  175. function Druid1(NPC,Spawn)
  176. FaceTarget(NPC, Spawn)
  177. Dialog.New(NPC, Spawn)
  178. Dialog.AddDialog("As a druid, you will become Nature's servant and companion, not her master. Nature is everywhere. If you respect her, she will become the greatest ally you have ever known. With your wisdom and her power, nothing shall defeat you.")
  179. Dialog.AddVoiceover("voiceover/english/hierophant_aldalad/qey_north/hierophant_aldalad021.mp3", 2608345231, 3745599287)
  180. PlayFlavor(NPC, "", "", "orate", 0, 0, Spawn)
  181. Dialog.AddOption("It is clear to me. I am called to be a druid.","Druid2" )
  182. Dialog.AddOption("What were my options again?","FinalClassTest" )
  183. Dialog.Start()
  184. end
  185. function Druid2(NPC,Spawn)
  186. FaceTarget(NPC, Spawn)
  187. Dialog.New(NPC, Spawn)
  188. Dialog.AddDialog("The path of a druid often requires more than just nurturing the land and its inhabitants. Often blights will have to be physically driven out, and this requires not only an awareness of one's surroundings, but also the strength to perform these feats. To this end, I have devised a test to determine your readiness to become a druid.")
  189. Dialog.AddVoiceover("voiceover/english/hierophant_aldalad/qey_north/hierophant_aldalad028.mp3", 774916388, 145472560)
  190. PlayFlavor(NPC, "", "", "nod", 0, 0, Spawn)
  191. Dialog.AddOption("What sort of challenges must I face?","Druid3" )
  192. Dialog.Start()
  193. end
  194. function Druid3(NPC,Spawn)
  195. FaceTarget(NPC, Spawn)
  196. Dialog.New(NPC, Spawn)
  197. Dialog.AddDialog("I cannot tell you exactly what you will face - only that you must use the skills and spells you have learned up to this point in order to win your way past it and become a druid. Remember that you will be alone with this. Are you ready to begin?")
  198. Dialog.AddVoiceover("voiceover/english/hierophant_aldalad/qey_north/hierophant_aldalad029.mp3", 3326972063, 1689451744)
  199. PlayFlavor(NPC, "", "", "ponder", 0, 0, Spawn)
  200. Dialog.AddOption("I am.","OfferDruid" )
  201. Dialog.AddOption("I will be shortly. I will return.")
  202. Dialog.Start()
  203. end
  204. function OfferDruid(NPC,Spawn)
  205. OfferQuest(NPC,Spawn,Druid)
  206. FaceTarget(NPC,Spawn)
  207. end
  208. function DruidAccepted(NPC,Spawn)
  209. FaceTarget(NPC, Spawn)
  210. Dialog.New(NPC, Spawn)
  211. Dialog.AddDialog("There will be no need to return to me when you have completed this trial, but go forth and put what you have learned into practice. You will know when you have earned the right to call yourself a druid. I will send you to where you need to go.")
  212. Dialog.AddVoiceover("voiceover/english/hierophant_aldalad/qey_north/hierophant_aldalad030.mp3", 110213528, 850594761)
  213. PlayFlavor(NPC, "", "", "agree", 0, 0, Spawn)
  214. Dialog.AddOption("I am ready.","DruidPort" )
  215. Dialog.Start()
  216. end
  217. function DruidPort(NPC,Spawn)
  218. Trial = GetZone("BurningAbode")
  219. Zone(Trial,Spawn,6.91, -0.20, 3.77, 348.55)
  220. end
  221. --SHAMAN
  222. function Shaman1(NPC,Spawn)
  223. FaceTarget(NPC, Spawn)
  224. Dialog.New(NPC, Spawn)
  225. Dialog.AddDialog("A shaman knows that death is but a journey to another adventure. If you choose this path, then those who have gone before you will guide your way through this mortal coil. By communing with your ancestors, the wisdom of the past is always within reach. The shaman speaks for the dead, and acts as a vessel to help others.")
  226. Dialog.AddVoiceover("voiceover/english/hierophant_aldalad/qey_north/hierophant_aldalad022.mp3", 921764949, 3161713723)
  227. PlayFlavor(NPC, "", "", "nod", 0, 0, Spawn)
  228. Dialog.AddOption("The spirits are with me and will always be my guide. I am a shaman.","OfferShaman" )
  229. Dialog.AddOption("What were my options again?","FinalClassTest" )
  230. Dialog.Start()
  231. end
  232. function OfferShaman(NPC,Spawn)
  233. OfferQuest(NPC,Spawn,Shaman)
  234. FaceTarget(NPC,Spawn)
  235. end
  236. function ShamanAccept(NPC,Spawn)
  237. FaceTarget(NPC, Spawn)
  238. Dialog.New(NPC, Spawn)
  239. Dialog.AddDialog("Then you must travel to the Southern part of the city where a home has reportedly become a site of restless spirits. Use the skills you have gained to unshackle them from this world and you will have proven yourself as a shaman. There will be no need to return to me, but be wary, spirits have powers even they can fathom.")
  240. -- Dialog.AddVoiceover("voiceover/english/hierophant_aldalad/qey_north/hierophant_aldalad030.mp3", 110213528, 850594761)
  241. PlayFlavor(NPC, "", "", "agree", 0, 0, Spawn)
  242. Dialog.AddOption("Thank you, Aldalad. I will pass this trial." )
  243. Dialog.Start()
  244. end