9
3

ShamanCertificationPapers.lua 10.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284
  1. --[[
  2. Script Name : ItemScripts/ShamanCertificationPapers.lua
  3. Script Author : Dorbin
  4. Script Date : 2023.06.15 03:06:11
  5. Script Purpose :
  6. :
  7. --]]
  8. local Quest = 5850
  9. function examined(Item, Player)
  10. conversation = CreateConversation()
  11. if GetClass(Player)==0 or GetClass(Player)==11 then
  12. AddConversationOption(conversation, "[Glance over the forms]","Intro")
  13. end
  14. if CanReceiveQuest(Player,Quest) then
  15. AddConversationOption(conversation, "[Turn in these papers for gear]","QuestStart")
  16. end
  17. AddConversationOption(conversation, "[Put the certificate away]","CloseItemConversation")
  18. StartDialogConversation(conversation, 2, Item, Player, "This certificate would make you a \"Shaman\" if you signed it and are a Commoner or Priest.\n\nTHIS ACTION IS FINAL!\n\nRead further if you wish to become a Shaman.")
  19. end
  20. function Intro(Item, Player)
  21. conversation = CreateConversation()
  22. AddConversationOption(conversation, ""..GetName(Player).." the Shaman","Class")
  23. AddConversationOption(conversation, "[Put the certificate away]","CloseItemConversation")
  24. StartDialogConversation(conversation, 2, Item, Player, "-- OFFICIAL DOCUMENT --\n\n I, "..GetName(Player)..", am a Shaman as proof by trainer [illegible scribbles].\n\nSigned,")
  25. end
  26. function Class(Item, Player)
  27. conversation = CreateConversation()
  28. if CanReceiveQuest(Player,Quest) then
  29. AddConversationOption(conversation, "[Turn in these papers for gear]","QuestStart")
  30. end
  31. AddConversationOption(conversation, "[Put the signed certificate away]","TaskDone")
  32. StartDialogConversation(conversation, 2, Item, Player, "You are now known as \n\n"..GetName(Player).." the Shaman.")
  33. if GetClass(Player)== 11 or GetClass(Player)== 0 then
  34. SetAdventureClass(Player,18)
  35. local level = GetLevel(Player)*5
  36. --WEAPON SKILLS
  37. if not HasSkill(Player, 2463145248) then -- Inspirations
  38. AddSkill(Player, 2463145248,1,level)
  39. SendMessage(Player, "You have learned the Inspirations skill")
  40. end
  41. if not HasSkill(Player, 3343700951) then -- Talismans/Shaman
  42. AddSkill(Player, 3343700951,1,level)
  43. SendMessage(Player, "You have learned the Talismans skill")
  44. end
  45. if not HasSkill(Player, 3421494576) then -- Crushing
  46. AddSkill(Player, 3421494576,1,level)
  47. SendMessage(Player, "You have learned the Crushing skill")
  48. end
  49. if not HasSkill(Player, 3048574950) then -- Piercing
  50. AddSkill(Player, 3048574950,1,level)
  51. SendMessage(Player, "You have learned the Piercing skill")
  52. end
  53. --CASTING SKILLS
  54. if not HasSkill(Player, 613995491) then -- Disruption
  55. AddSkill(Player, 613995491,1,level)
  56. SendMessage(Player, "You have learned the Disruption skill")
  57. end
  58. if not HasSkill(Player, 366253016) then -- Ministration
  59. AddSkill(Player, 366253016,1,level)
  60. SendMessage(Player, "You have learned the Ministration skill")
  61. end
  62. if not HasSkill(Player, 3587918036) then -- Ordination
  63. AddSkill(Player, 3587918036,1,level)
  64. SendMessage(Player, "You have learned the Ordination skill")
  65. end
  66. if not HasSkill(Player, 882983852) then -- Subjugation
  67. AddSkill(Player, 882983852,1,level)
  68. SendMessage(Player, "You have learned the Subjugation skill")
  69. end
  70. if not HasSkill(Player, 2638198038) then -- Focus
  71. AddSkill(Player, 2638198038,1,level)
  72. SendMessage(Player, "You have learned the Focus skill")
  73. end
  74. --WEAPON SKILLS
  75. if not HasSkill(Player, 4037812502) then -- Buckler
  76. AddSkill(Player, 4037812502,1,level)
  77. SendMessage(Player, "You are now more proficient with a Buckler")
  78. end
  79. if not HasSkill(Player, 770311065) then -- Mace
  80. AddSkill(Player, 770311065,1,level)
  81. SendMessage(Player, "You are now more proficient with a Mace")
  82. end
  83. if not HasSkill(Player, 1616998748) then -- Spear
  84. AddSkill(Player, 1616998748,1,level)
  85. SendMessage(Player, "You are now more proficient with a Spear")
  86. end
  87. if not HasSkill(Player, 554333641) then -- Hammer
  88. AddSkill(Player, 554333641,1,level)
  89. SendMessage(Player, "You are now more proficient with a Hammer")
  90. end
  91. if not HasSkill(Player, 1653482350) then -- Great Hammer
  92. AddSkill(Player, 1653482350,1,level)
  93. SendMessage(Player, "You are now more proficient with a Great Hammer")
  94. end
  95. if not HasSkill(Player, 3180399725) then -- Staff(2h)
  96. AddSkill(Player, 3180399725,1,level)
  97. SendMessage(Player, "You are now more proficient with a Staff")
  98. end
  99. --REMOVE SKILLS
  100. -- Remove Fighter
  101. if HasSkill(Player, 1408356869) then -- Martial/Fighter
  102. RemoveSkill(Player, 1408356869)
  103. end
  104. if HasSkill(Player, 1124719197) then -- Tactics/Warrior
  105. RemoveSkill(Player, 1124719197)
  106. end
  107. if HasSkill(Player, 433335062) then -- Berserk/Berserker
  108. RemoveSkill(Player, 433335062)
  109. end
  110. if HasSkill(Player, 1209716810) then -- Protection/Guardian
  111. RemoveSkill(Player, 1209716810)
  112. end
  113. if HasSkill(Player, 3856706740) then -- Brawl/Brawling
  114. RemoveSkill(Player, 3856706740)
  115. end
  116. if HasSkill(Player, 2011726342) then -- Tranquility/Monk
  117. RemoveSkill(Player, 2011726342)
  118. end
  119. if HasSkill(Player, 3067436248) then -- Physicality/Bruiser
  120. RemoveSkill(Player, 3067436248)
  121. end
  122. if HasSkill(Player, 3809066846) then -- Faith/Crusader
  123. RemoveSkill(Player, 3809066846)
  124. end
  125. if HasSkill(Player, 90523872) then -- Determined Faith/Paladin
  126. RemoveSkill(Player, 90523872)
  127. end
  128. if HasSkill(Player, 2741805322) then -- Determined Zeal/Shadowknight
  129. RemoveSkill(Player, 2741805322)
  130. end
  131. --Remove Scout
  132. if HasSkill(Player, 1921433074) then -- Reconnaissance/Scout
  133. RemoveSkill(Player, 1921433074)
  134. end
  135. if HasSkill(Player, 1311635100) then -- Melodies/Bard
  136. RemoveSkill(Player, 1311635100)
  137. end
  138. if HasSkill(Player, 296246391) then -- Ballads/Troubador
  139. RemoveSkill(Player, 296246391)
  140. end
  141. if HasSkill(Player, 340921594) then -- Dirges/Dirge
  142. RemoveSkill(Player, 340921594)
  143. end
  144. if HasSkill(Player, 1514256692) then -- Skulldugery/Rogue
  145. RemoveSkill(Player, 1514256692)
  146. end
  147. if HasSkill(Player, 3167106577) then -- Stalking/Predator
  148. RemoveSkill(Player, 3167106577)
  149. end
  150. if HasSkill(Player, 2663054519) then -- Swashbuckling/Swashbuckler
  151. RemoveSkill(Player, 2663054519)
  152. end
  153. if HasSkill(Player, 1519965519) then -- Banditry/Brigand
  154. RemoveSkill(Player, 1519965519)
  155. end
  156. if HasSkill(Player, 1400160844) then -- Archery/Ranger
  157. RemoveSkill(Player, 1400160844)
  158. end
  159. if HasSkill(Player, 2711101135) then -- Assassination/Assassin
  160. RemoveSkill(Player, 2711101135)
  161. end
  162. --Removed Priest
  163. if HasSkill(Player, 3341842907) then -- Theurgy/Cleric
  164. RemoveSkill(Player, 3341842907)
  165. end
  166. if HasSkill(Player, 2581053277) then -- Regimens/Templar
  167. RemoveSkill(Player, 2581053277)
  168. end
  169. if HasSkill(Player, 1829443087) then -- Inquisitions/Inquisitor
  170. RemoveSkill(Player, 1829443087)
  171. end
  172. if HasSkill(Player, 3282420779) then -- Archegenesis/Druid
  173. RemoveSkill(Player, 3282420779)
  174. end
  175. if HasSkill(Player, 1624274802) then -- Nature's Reckoning/Fury
  176. RemoveSkill(Player, 1624274802)
  177. end
  178. if HasSkill(Player, 1040683335) then -- Nature's Refuge/Warden
  179. RemoveSkill(Player, 1040683335)
  180. end
  181. if HasSkill(Player, 3467160477) then -- Fetichisms/Mystic
  182. RemoveSkill(Player, 3467160477)
  183. end
  184. if HasSkill(Player, 3191839982) then -- Vehemence/Defiler
  185. RemoveSkill(Player, 3191839982)
  186. end
  187. --Remove Mage
  188. if HasSkill(Player, 3820670534) then -- Evocations/Mage
  189. RemoveSkill(Player, 3820670534)
  190. end
  191. if HasSkill(Player, 287643040) then -- Enchantments/Enchanter
  192. RemoveSkill(Player, 287643040)
  193. end
  194. if HasSkill(Player, 2898101972) then -- Hallucinations/Illusionist
  195. RemoveSkill(Player, 2898101972)
  196. end
  197. if HasSkill(Player, 2950599749) then -- Protean/Coecerer
  198. RemoveSkill(Player, 2950599749)
  199. end
  200. if HasSkill(Player, 2533124061) then -- Sorcery/Sorcerer
  201. RemoveSkill(Player, 2533124061)
  202. end
  203. if HasSkill(Player, 2662430630) then -- Elemental Mastery/Wizard
  204. RemoveSkill(Player, 2662430630)
  205. end
  206. if HasSkill(Player, 193411854) then -- Noctivagance/Warlock
  207. RemoveSkill(Player, 193411854)
  208. end
  209. if HasSkill(Player, 2120065377) then -- Legerdemain/Summoner
  210. RemoveSkill(Player, 2120065377)
  211. end
  212. if HasSkill(Player, 2042842194) then -- Conjurations/Conjurer
  213. RemoveSkill(Player, 2042842194)
  214. end
  215. if HasSkill(Player, 289471519) then -- Sepulchers/Necromancer
  216. RemoveSkill(Player, 289471519)
  217. end
  218. --REMOVE WEAPON
  219. if HasSkill(Player, 2246237129) then -- Medium Armor
  220. RemoveSkill(Player, 2246237129)
  221. end
  222. if HasSkill(Player, 241174330) then -- Heavy Armor
  223. RemoveSkill(Player, 241174330)
  224. end
  225. if HasSkill(Player, 3177806075) then -- Fists
  226. RemoveSkill(Player, 3177806075)
  227. end
  228. if HasSkill(Player, 2292577688) then -- Great Sword
  229. RemoveSkill(Player, 2292577688)
  230. end
  231. if HasSkill(Player, 2954459351) then -- Great Axe
  232. RemoveSkill(Player, 2954459351)
  233. end
  234. if HasSkill(Player, 1653482350) then -- Great Spear
  235. RemoveSkill(Player, 1653482350)
  236. end
  237. if HasSkill(Player, 3173504370) then -- Round Shield
  238. RemoveSkill(Player, 3173504370)
  239. end
  240. if HasSkill(Player, 2608320658) then -- Kite Shield
  241. RemoveSkill(Player, 2608320658)
  242. end
  243. if HasSkill(Player, 570458645) then -- Tower Shield
  244. RemoveSkill(Player, 570458645)
  245. end
  246. if HasSkill(Player, 545043066) then -- Symbol
  247. RemoveSkill(Player, 545043066)
  248. end
  249. SendMessage(Player, "Congratulations! You are a Shaman.","yellow")
  250. SendPopUpMessage(Player, "Congratulations! You are a Shaman.",250,250,200)
  251. ApplySpellVisual(Player, 324)
  252. PlaySound(Player, "sounds/test/endquest.wav", GetX(Player), GetY(Player), GetZ(Player), Player)
  253. SetPlayerLevel(Player,10)
  254. end
  255. end
  256. function QuestStart(Item,Player)
  257. OfferQuest(nil,Player,Quest)
  258. conversation = CreateConversation()
  259. AddConversationOption(conversation, "[Put the signed certificate away]","TaskDone")
  260. StartDialogConversation(conversation, 2, Item, Player, "The Shady Swashbuckler might have some gear I can use...")
  261. end
  262. function TaskDone(Item,Player)
  263. CloseItemConversation(Item,Player)
  264. if HasItem(Player,1001103) then
  265. RemoveItem(Player,1001103,1)
  266. end
  267. end