TeganFrostfist.lua 5.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129
  1. --[[
  2. Script Name : SpawnScripts/ScaleYard/TeganFrostfist.lua
  3. Script Purpose : Tegan Frostfist
  4. Script Author : torsten
  5. Script Date : 2022.07.25
  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,4)
  16. if choice == 1 then
  17. PlayVoice(NPC, "voiceover/english/voice_emotes/greetings/greetings_1_1042.mp3", 0, 0, Spawn)
  18. elseif choice == 2 then
  19. PlayVoice(NPC, "voiceover/english/voice_emotes/greetings/greetings_2_1002.mp3", 0, 0, Spawn)
  20. elseif choice == 3 then
  21. PlayVoice(NPC, "voiceover/english/voice_emotes/greetings/greetings_3_1002.mp3", 0, 0, Spawn)
  22. elseif choice == 4 then
  23. PlayVoice(NPC, "voiceover/english/voice_emotes/greetings/greetings_2_1004.mp3", 0, 0, Spawn)
  24. end
  25. end
  26. function respawn(NPC)
  27. spawn(NPC)
  28. end
  29. function hailed(NPC, Spawn)
  30. FaceTarget(NPC, Spawn)
  31. if HasQuest(Spawn,5863) and GetQuestStep(Spawn,5863) == 8 then
  32. Dialog1(NPC,Spawn)
  33. elseif GetTradeskillLevel(Spawn) <2 then
  34. RandomGreeting(NPC,Spawn)
  35. conversation = CreateConversation()
  36. --not HasItem(Spawn, ARTISAN_ESSENTIALS_VOLUME_2, 1) then
  37. RandomGreeting(NPC,Spawn)
  38. AddConversationOption(conversation, "Yes, please teach me.", "dlg_39_1")
  39. AddConversationOption(conversation, "No, not at the moment.")
  40. 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?")
  41. else
  42. RandomGreeting(NPC,Spawn)
  43. 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")
  44. -- 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)
  45. end
  46. end
  47. function dlg_39_1(NPC, Spawn)
  48. FaceTarget(NPC, Spawn)
  49. conversation = CreateConversation()
  50. if GetTradeskillLevel(Spawn) <2 then
  51. Quest = GetQuest(Spawn,5863)
  52. SummonItem(Spawn,1030001,1)
  53. SetTradeskillLevel(Spawn,2)
  54. SetTradeskillClass(Spawn,1)
  55. SendMessage(Spawn, "You are now an Artisan!")
  56. SendPopUpMessage(Spawn, "You are now an Artisan!", 200, 200, 200)
  57. end
  58. --[[ Revamped
  59. -- artisan essentials volume 2
  60. SummonItem(Spawn, ARTISAN_ESSENTIALS_VOLUME_2, 1)
  61. ]]--
  62. AddConversationOption(conversation, "I will start on that now.")
  63. 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.")
  64. end
  65. function Dialog1(NPC,Spawn)
  66. SetStepComplete(Spawn,5863,8)
  67. FaceTarget(NPC, Spawn)
  68. Dialog.New(NPC, Spawn)
  69. PlayFlavor(NPC, "", "", "hello", 0, 0, Spawn)
  70. Dialog.AddDialog("Hail, friend! Don't be shy! The best part about working for The War Hagglers is that you get to meet so many new people.")
  71. Dialog.AddVoiceover("voiceover/english/tegan_frostfist/fprt_hood06/100_trd_tegan_frostfist_joining_99e9b991.mp3",2604105254,1796655859)
  72. Dialog.AddOption("Just looking around. As you were.")
  73. Dialog.AddOption("What can I do here?", "CanDo")
  74. if GetTradeskillLevel(Spawn)<2 then
  75. Dialog.AddOption("I'm rather new at crafting. Can you help me?", "HelpMe")
  76. end
  77. Dialog.Start()
  78. end
  79. function CanDo(NPC,Spawn)
  80. FaceTarget(NPC, Spawn)
  81. Dialog.New(NPC, Spawn)
  82. PlayFlavor(NPC, "", "", "orate", 0, 0, Spawn)
  83. 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.")
  84. Dialog.AddOption("Anything else I should know?", "CanDo2")
  85. if GetTradeskillLevel(Spawn)<2 then
  86. Dialog.AddOption("I'm rather new at crafting. Can you help me?", "HelpMe")
  87. end
  88. Dialog.Start()
  89. end
  90. function CanDo2(NPC,Spawn)
  91. FaceTarget(NPC, Spawn)
  92. Dialog.New(NPC, Spawn)
  93. PlayFlavor(NPC, "", "", "nod", 0, 0, Spawn)
  94. 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!")
  95. Dialog.AddOption("Thank you for all the information!")
  96. if GetTradeskillLevel(Spawn)<2 then
  97. Dialog.AddOption("I'm rather new at crafting. Can you help me?", "HelpMe")
  98. end
  99. Dialog.Start()
  100. end
  101. function HelpMe(NPC,Spawn)
  102. FaceTarget(NPC, Spawn)
  103. Dialog.New(NPC, Spawn)
  104. PlayFlavor(NPC, "", "", "nod", 0, 0, Spawn)
  105. Dialog.AddDialog("In order to be competitive in today's marketplace, The War Hagglers 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.")
  106. Dialog.AddOption("What can I do here?", "CanDo")
  107. Dialog.AddOption("Thank you for all the information!")
  108. if GetTradeskillLevel(Spawn) <2 then
  109. SummonItem(Spawn,1030001,1)
  110. SetTradeskillLevel(Spawn,2)
  111. SetTradeskillClass(Spawn,1)
  112. SendMessage(Spawn, "You are now an Artisan!")
  113. SendPopUpMessage(Spawn, "You are now an Artisan!", 200, 200, 200)
  114. end
  115. Dialog.Start()
  116. end