9
3

DruidCertificationPapers.lua 10 KB

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