path_of_the_shaman.lua 11 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308
  1. --[[
  2. Script Name : Quests/Hallmark/path_of_the_shaman.lua
  3. Script Author : Dorbin
  4. Script Date : 2022.11.19 05:11:32
  5. Script Purpose :
  6. Zone : Hallmark
  7. Quest Giver:
  8. Preceded by: None
  9. Followed by:
  10. --]]
  11. require "SpawnScripts/Generic/DialogModule"
  12. function Init(Quest)
  13. AddQuestStepKill(Quest, 1, "I must subdue the first spirit.", 1, 100, "I must venture into the house in South Qeynos, located among the middle row of buildings, and subdue the spirits within.", 11, 2140028)
  14. AddQuestStepKill(Quest, 2, "I must subdue the second spirit.", 1, 100, "I must venture into the house in South Qeynos, located among the middle row of buildings, and subdue the spirits within.", 11, 2140029)
  15. AddQuestStepKill(Quest, 3, "I must subdue the third spirit.", 1, 100, "I must venture into the house in South Qeynos, located among the middle row of buildings, and subdue the spirits within.", 11, 2140027)
  16. AddQuestStepCompleteAction(Quest, 1, "Step1Complete")
  17. AddQuestStepCompleteAction(Quest, 2, "Step2Complete")
  18. AddQuestStepCompleteAction(Quest, 3, "QuestComplete")
  19. end
  20. function Accepted(Quest, QuestGiver, Player)
  21. FaceTarget(QuestGiver, Player)
  22. Dialog.New(QuestGiver, Player)
  23. 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.")
  24. -- Dialog.AddVoiceover("voiceover/english/hierophant_aldalad/qey_north/hierophant_aldalad030.mp3", 110213528, 850594761)
  25. PlayFlavor(QuestGiver, "", "", "agree", 0, 0, Player)
  26. Dialog.AddOption("Thank you, Aldalad. I will pass this trial." )
  27. Dialog.Start()
  28. if GetQuestStep(Player,5879)==1 then
  29. SetStepComplete(Player,5879,1)
  30. end
  31. end
  32. function Declined(Quest, QuestGiver, Player)
  33. -- Add dialog here for when the quest is declined
  34. end
  35. function Deleted(Quest, QuestGiver, Player)
  36. -- Remove any quest specific items here when the quest is deleted
  37. end
  38. function Step1Complete(Quest, QuestGiver, Player)
  39. UpdateQuestStepDescription(Quest, 1, "I have subdued the first spirit.")
  40. QuestCheck(Quest, QuestGiver, Player)
  41. end
  42. function Step2Complete(Quest, QuestGiver, Player)
  43. UpdateQuestStepDescription(Quest, 2, "I have subdued the second spirit.")
  44. QuestCheck(Quest, QuestGiver, Player)
  45. end
  46. function QuestComplete(Quest, QuestGiver, Player)
  47. -- The following UpdateQuestStepDescription and UpdateTaskGroupDescription are not needed, parser adds them for completion in case stuff needs to be moved around
  48. UpdateQuestStepDescription(Quest, 3, "I have subdued the third spirit.")
  49. QuestCheck(Quest, QuestGiver, Player)
  50. end
  51. function QuestCheck(Quest, QuestGiver, Player)
  52. if QuestStepIsComplete(Player,5776,1) and QuestStepIsComplete(Player,5776,2) and QuestStepIsComplete(Player,5776,3) then
  53. UpdateQuestTaskGroupDescription(Quest, 1, "I have ventured into the house in South Qeynos and subdued the spirits within.")
  54. if GetClass(Player)== 11 then
  55. SetAdventureClass(Player,18)
  56. SetPlayerLevel(Player,10)
  57. SendMessage(Player, "Congratulations! You are a Shaman.","yellow")
  58. SendPopUpMessage(Player, "Congratulations! You are a Shaman.",250,250,200)
  59. ApplySpellVisual(Player, 324)
  60. PlaySound(Player, "sounds/test/endquest.wav", GetX(Player), GetY(Player), GetZ(Player), Player)
  61. local level = GetLevel(Player)*5
  62. --WEAPON SKILLS
  63. if not HasSkill(Player, 2463145248) then -- Inspirations
  64. AddSkill(Player, 2463145248,1,level)
  65. SendMessage(Player, "You have learned the Inspirations skill")
  66. end
  67. if not HasSkill(Player, 3343700951) then -- Talismans/Shaman
  68. AddSkill(Player, 3343700951,1,level)
  69. SendMessage(Player, "You have learned the Talismans skill")
  70. end
  71. if not HasSkill(Player, 3421494576) then -- Crushing
  72. AddSkill(Player, 3421494576,1,level)
  73. SendMessage(Player, "You have learned the Crushing skill")
  74. end
  75. if not HasSkill(Player, 3048574950) then -- Piercing
  76. AddSkill(Player, 3048574950,1,level)
  77. SendMessage(Player, "You have learned the Piercing skill")
  78. end
  79. --CASTING SKILLS
  80. if not HasSkill(Player, 613995491) then -- Disruption
  81. AddSkill(Player, 613995491,1,level)
  82. SendMessage(Player, "You have learned the Disruption skill")
  83. end
  84. if not HasSkill(Player, 366253016) then -- Ministration
  85. AddSkill(Player, 366253016,1,level)
  86. SendMessage(Player, "You have learned the Ministration skill")
  87. end
  88. if not HasSkill(Player, 3587918036) then -- Ordination
  89. AddSkill(Player, 3587918036,1,level)
  90. SendMessage(Player, "You have learned the Ordination skill")
  91. end
  92. if not HasSkill(Player, 882983852) then -- Subjugation
  93. AddSkill(Player, 882983852,1,level)
  94. SendMessage(Player, "You have learned the Subjugation skill")
  95. end
  96. if not HasSkill(Player, 2638198038) then -- Focus
  97. AddSkill(Player, 2638198038,1,level)
  98. SendMessage(Player, "You have learned the Focus skill")
  99. end
  100. --WEAPON SKILLS
  101. if not HasSkill(Player, 4037812502) then -- Buckler
  102. AddSkill(Player, 4037812502,1,level)
  103. SendMessage(Player, "You are now more proficient with a Buckler")
  104. end
  105. if not HasSkill(Player, 770311065) then -- Mace
  106. AddSkill(Player, 770311065,1,level)
  107. SendMessage(Player, "You are now more proficient with a Mace")
  108. end
  109. if not HasSkill(Player, 1616998748) then -- Spear
  110. AddSkill(Player, 1616998748,1,level)
  111. SendMessage(Player, "You are now more proficient with a Spear")
  112. end
  113. if not HasSkill(Player, 554333641) then -- Hammer
  114. AddSkill(Player, 554333641,1,level)
  115. SendMessage(Player, "You are now more proficient with a Hammer")
  116. end
  117. if not HasSkill(Player, 1653482350) then -- Great Hammer
  118. AddSkill(Player, 1653482350,1,level)
  119. SendMessage(Player, "You are now more proficient with a Great Hammer")
  120. end
  121. if not HasSkill(Player, 3180399725) then -- Staff(2h)
  122. AddSkill(Player, 3180399725,1,level)
  123. SendMessage(Player, "You are now more proficient with a Staff")
  124. end
  125. --REMOVE SKILLS
  126. -- Remove Fighter
  127. if HasSkill(Player, 1408356869) then -- Martial/Fighter
  128. RemoveSkill(Player, 1408356869)
  129. end
  130. if HasSkill(Player, 1124719197) then -- Tactics/Warrior
  131. RemoveSkill(Player, 1124719197)
  132. end
  133. if HasSkill(Player, 433335062) then -- Berserk/Berserker
  134. RemoveSkill(Player, 433335062)
  135. end
  136. if HasSkill(Player, 1209716810) then -- Protection/Guardian
  137. RemoveSkill(Player, 1209716810)
  138. end
  139. if HasSkill(Player, 3856706740) then -- Brawl/Brawling
  140. RemoveSkill(Player, 3856706740)
  141. end
  142. if HasSkill(Player, 2011726342) then -- Tranquility/Monk
  143. RemoveSkill(Player, 2011726342)
  144. end
  145. if HasSkill(Player, 3067436248) then -- Physicality/Bruiser
  146. RemoveSkill(Player, 3067436248)
  147. end
  148. if HasSkill(Player, 3809066846) then -- Faith/Crusader
  149. RemoveSkill(Player, 3809066846)
  150. end
  151. if HasSkill(Player, 90523872) then -- Determined Faith/Paladin
  152. RemoveSkill(Player, 90523872)
  153. end
  154. if HasSkill(Player, 2741805322) then -- Determined Zeal/Shadowknight
  155. RemoveSkill(Player, 2741805322)
  156. end
  157. --Remove Scout
  158. if HasSkill(Player, 1921433074) then -- Reconnaissance/Scout
  159. RemoveSkill(Player, 1921433074)
  160. end
  161. if HasSkill(Player, 1311635100) then -- Melodies/Bard
  162. RemoveSkill(Player, 1311635100)
  163. end
  164. if HasSkill(Player, 296246391) then -- Ballads/Troubador
  165. RemoveSkill(Player, 296246391)
  166. end
  167. if HasSkill(Player, 340921594) then -- Dirges/Dirge
  168. RemoveSkill(Player, 340921594)
  169. end
  170. if HasSkill(Player, 1514256692) then -- Skulldugery/Rogue
  171. RemoveSkill(Player, 1514256692)
  172. end
  173. if HasSkill(Player, 3167106577) then -- Stalking/Predator
  174. RemoveSkill(Player, 3167106577)
  175. end
  176. if HasSkill(Player, 2663054519) then -- Swashbuckling/Swashbuckler
  177. RemoveSkill(Player, 2663054519)
  178. end
  179. if HasSkill(Player, 1519965519) then -- Banditry/Brigand
  180. RemoveSkill(Player, 1519965519)
  181. end
  182. if HasSkill(Player, 1400160844) then -- Archery/Ranger
  183. RemoveSkill(Player, 1400160844)
  184. end
  185. if HasSkill(Player, 2711101135) then -- Assassination/Assassin
  186. RemoveSkill(Player, 2711101135)
  187. end
  188. --Removed Priest
  189. if HasSkill(Player, 3341842907) then -- Theurgy/Cleric
  190. RemoveSkill(Player, 3341842907)
  191. end
  192. if HasSkill(Player, 2581053277) then -- Regimens/Templar
  193. RemoveSkill(Player, 2581053277)
  194. end
  195. if HasSkill(Player, 1829443087) then -- Inquisitions/Inquisitor
  196. RemoveSkill(Player, 1829443087)
  197. end
  198. if HasSkill(Player, 3282420779) then -- Archegenesis/Druid
  199. RemoveSkill(Player, 3282420779)
  200. end
  201. if HasSkill(Player, 1624274802) then -- Nature's Reckoning/Fury
  202. RemoveSkill(Player, 1624274802)
  203. end
  204. if HasSkill(Player, 1040683335) then -- Nature's Refuge/Warden
  205. RemoveSkill(Player, 1040683335)
  206. end
  207. if HasSkill(Player, 3467160477) then -- Fetichisms/Mystic
  208. RemoveSkill(Player, 3467160477)
  209. end
  210. if HasSkill(Player, 3191839982) then -- Vehemence/Defiler
  211. RemoveSkill(Player, 3191839982)
  212. end
  213. --Remove Mage
  214. if HasSkill(Player, 3820670534) then -- Evocations/Mage
  215. RemoveSkill(Player, 3820670534)
  216. end
  217. if HasSkill(Player, 287643040) then -- Enchantments/Enchanter
  218. RemoveSkill(Player, 287643040)
  219. end
  220. if HasSkill(Player, 2898101972) then -- Hallucinations/Illusionist
  221. RemoveSkill(Player, 2898101972)
  222. end
  223. if HasSkill(Player, 2950599749) then -- Protean/Coecerer
  224. RemoveSkill(Player, 2950599749)
  225. end
  226. if HasSkill(Player, 2533124061) then -- Sorcery/Sorcerer
  227. RemoveSkill(Player, 2533124061)
  228. end
  229. if HasSkill(Player, 2662430630) then -- Elemental Mastery/Wizard
  230. RemoveSkill(Player, 2662430630)
  231. end
  232. if HasSkill(Player, 193411854) then -- Noctivagance/Warlock
  233. RemoveSkill(Player, 193411854)
  234. end
  235. if HasSkill(Player, 2120065377) then -- Legerdemain/Summoner
  236. RemoveSkill(Player, 2120065377)
  237. end
  238. if HasSkill(Player, 2042842194) then -- Conjurations/Conjurer
  239. RemoveSkill(Player, 2042842194)
  240. end
  241. if HasSkill(Player, 289471519) then -- Sepulchers/Necromancer
  242. RemoveSkill(Player, 289471519)
  243. end
  244. --REMOVE WEAPON
  245. if HasSkill(Player, 2246237129) then -- Medium Armor
  246. RemoveSkill(Player, 2246237129)
  247. end
  248. if HasSkill(Player, 241174330) then -- Heavy Armor
  249. RemoveSkill(Player, 241174330)
  250. end
  251. if HasSkill(Player, 3177806075) then -- Fists
  252. RemoveSkill(Player, 3177806075)
  253. end
  254. if HasSkill(Player, 2292577688) then -- Great Sword
  255. RemoveSkill(Player, 2292577688)
  256. end
  257. if HasSkill(Player, 2954459351) then -- Great Axe
  258. RemoveSkill(Player, 2954459351)
  259. end
  260. if HasSkill(Player, 1653482350) then -- Great Spear
  261. RemoveSkill(Player, 1653482350)
  262. end
  263. if HasSkill(Player, 3173504370) then -- Round Shield
  264. RemoveSkill(Player, 3173504370)
  265. end
  266. if HasSkill(Player, 2608320658) then -- Kite Shield
  267. RemoveSkill(Player, 2608320658)
  268. end
  269. if HasSkill(Player, 570458645) then -- Tower Shield
  270. RemoveSkill(Player, 570458645)
  271. end
  272. if HasSkill(Player, 545043066) then -- Symbol
  273. RemoveSkill(Player, 545043066)
  274. end
  275. end
  276. UpdateQuestDescription(Quest, "The spirits I encountered proved quite spiteful, obviously intent on destroying all life around them. Perhaps their souls were unable to find peace. Even so, after my trial I proved that I am worthy to be a shaman.")
  277. GiveQuestReward(Quest, Player)
  278. end
  279. end
  280. function Reload(Quest, QuestGiver, Player, Step)
  281. if Step == 1 then
  282. Step1Complete(Quest, QuestGiver, Player)
  283. elseif Step == 2 then
  284. Step2Complete(Quest, QuestGiver, Player)
  285. elseif Step == 3 then
  286. QuestComplete(Quest, QuestGiver, Player)
  287. end
  288. end