KorkoofCrackstone.lua 5.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127
  1. --[[
  2. Script Name : SpawnScripts/BigBend/KorkoofCrackstone.lua
  3. Script Purpose : Korkoof Crackstone
  4. Script Author : Dorbin
  5. Script Date : 2022.07.13
  6. Script Notes : Auto-Generated Conversation from PacketParser Data
  7. --]]
  8. require "SpawnScripts/Generic/DialogModule"
  9. dofile("SpawnScripts/Generic/GenericVoiceOvers.lua")
  10. -- Item ID's
  11. local ARTISAN_ESSENTIALS_VOLUME_2 = 31373
  12. function spawn(NPC)
  13. end
  14. function RandomGreeting(NPC,Spawn)
  15. local choice = MakeRandomInt(1,3)
  16. if choice == 1 then
  17. PlayVoice(NPC, "voiceover/english/voice_emotes/greetings/greetings_2_1054.mp3", 0, 0, Spawn)
  18. elseif choice == 2 then
  19. PlayVoice(NPC, "voiceover/english/voice_emotes/greetings/greetings_1_1054.mp3", 0, 0, Spawn)
  20. elseif choice == 3 then
  21. PlayVoice(NPC, "voiceover/english/voice_emotes/greetings/greetings_3_1054.mp3", 0, 0, Spawn)
  22. end
  23. end
  24. function respawn(NPC)
  25. spawn(NPC)
  26. end
  27. function hailed(NPC, Spawn)
  28. FaceTarget(NPC, Spawn)
  29. if HasQuest(Spawn,5860) and GetQuestStep(Spawn,5860) == 8 then
  30. Dialog1(NPC,Spawn)
  31. elseif GetTradeskillLevel(Spawn) <2 then
  32. RandomGreeting(NPC,Spawn)
  33. conversation = CreateConversation()
  34. --not HasItem(Spawn, ARTISAN_ESSENTIALS_VOLUME_2, 1) then
  35. RandomGreeting(NPC,Spawn)
  36. AddConversationOption(conversation, "Yes, please teach me.", "dlg_39_1")
  37. AddConversationOption(conversation, "No, not at the moment.")
  38. StartConversation(conversation, NPC, Spawn, "You show interest in the crafting trade, good. We can always use talented artisans. I can help you get started, would you be interested?")
  39. else
  40. RandomGreeting(NPC,Spawn)
  41. Say(NPC,"Good day! If you are looking for more crafting training, seek out the trainers in West Freeport. They can help you beyond the basics I provide.","Spawn")
  42. -- Say(NPC, "I have nothing else to teach you for the moment. Please return to me when you have earned enough experience to choose your profession.", Spawn)
  43. end
  44. end
  45. function dlg_39_1(NPC, Spawn)
  46. FaceTarget(NPC, Spawn)
  47. conversation = CreateConversation()
  48. if GetTradeskillLevel(Spawn) <2 then
  49. Quest = GetQuest(Spawn,5860)
  50. SummonItem(Spawn,1030001,1)
  51. SetTradeskillLevel(Spawn,2)
  52. SetTradeskillClass(Spawn,1)
  53. SendMessage(Spawn, "You are now an Artisan!")
  54. SendPopUpMessage(Spawn, "You are now an Artisan!", 200, 200, 200)
  55. end
  56. --[[ Revamped
  57. -- artisan essentials volume 2
  58. SummonItem(Spawn, ARTISAN_ESSENTIALS_VOLUME_2, 1)
  59. ]]--
  60. AddConversationOption(conversation, "I will start on that now.")
  61. StartConversation(conversation, NPC, Spawn, "There, you now have knowledge required to begin crafting. Speak to the Tradeskill Tutor for more detailed guidance on learning to craft, if you are interested in more information. Return to me when you are ready to select a crafting specialty.")
  62. end
  63. function Dialog1(NPC,Spawn)
  64. SetStepComplete(Spawn,5860,8)
  65. FaceTarget(NPC, Spawn)
  66. Dialog.New(NPC, Spawn)
  67. PlayFlavor(NPC, "", "", "no", 0, 0, Spawn)
  68. Dialog.AddDialog("I've no need for the weak. If you can handle yourself, then you can join The Ransackers Annex. Are you qualifed to be one of us?")
  69. Dialog.AddVoiceover("voiceover/english/korkoof_crackstone/fprt_hood1/100_trd_korkoof_crackstone_joining_649a7bb8.mp3", 1321833842, 3908486427)
  70. Dialog.AddOption("Just looking around. As you were.")
  71. Dialog.AddOption("What can I do here?", "CanDo")
  72. if GetTradeskillLevel(Spawn)<2 then
  73. Dialog.AddOption("I'm rather new at crafting. Can you help me?", "HelpMe")
  74. end
  75. Dialog.Start()
  76. end
  77. function CanDo(NPC,Spawn)
  78. FaceTarget(NPC, Spawn)
  79. Dialog.New(NPC, Spawn)
  80. PlayFlavor(NPC, "", "", "orate", 0, 0, Spawn)
  81. Dialog.AddDialog("Many things can be done at a tradeskill society and there are many in the city... but ours is obviously the best! Each is equipped with quality crafting stations and fuels needed to become proficient at any tradeskill class you might desire.")
  82. Dialog.AddOption("Anything else I should know?", "CanDo2")
  83. if GetTradeskillLevel(Spawn)<2 then
  84. Dialog.AddOption("I'm rather new at crafting. Can you help me?", "HelpMe")
  85. end
  86. Dialog.Start()
  87. end
  88. function CanDo2(NPC,Spawn)
  89. FaceTarget(NPC, Spawn)
  90. Dialog.New(NPC, Spawn)
  91. PlayFlavor(NPC, "", "", "nod", 0, 0, Spawn)
  92. Dialog.AddDialog("Our society also has our very own Broker, who you can talk to in order to buy and sell items from other adventurers. A very handy connection, indeed!")
  93. Dialog.AddOption("Thank you for all the information!")
  94. if GetTradeskillLevel(Spawn)<2 then
  95. Dialog.AddOption("I'm rather new at crafting. Can you help me?", "HelpMe")
  96. end
  97. Dialog.Start()
  98. end
  99. function HelpMe(NPC,Spawn)
  100. FaceTarget(NPC, Spawn)
  101. Dialog.New(NPC, Spawn)
  102. PlayFlavor(NPC, "", "", "nod", 0, 0, Spawn)
  103. Dialog.AddDialog("In order to be competitive in today's marketplace, The Ransackers Annex provides you with this basic guide to commerce. You will learn many things on your own over time, so do not consider this book your only guide to success. Rely on your own resources and skills and you will prosper.")
  104. Dialog.AddOption("What can I do here?", "CanDo")
  105. Dialog.AddOption("Thank you for all the information!")
  106. if GetTradeskillLevel(Spawn) <2 then
  107. SummonItem(Spawn,1030001,1)
  108. SetTradeskillLevel(Spawn,2)
  109. SetTradeskillClass(Spawn,1)
  110. SendMessage(Spawn, "You are now an Artisan!")
  111. SendPopUpMessage(Spawn, "You are now an Artisan!", 200, 200, 200)
  112. end
  113. Dialog.Start()
  114. end