three_bushels_fresh.lua 4.1 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889
  1. --[[
  2. Script Name : Quests/QeynosHarbor/three_bushels_fresh.lua
  3. Script Author : Dorbin
  4. Script Date : 2022.05.24 04:05:33
  5. Script Purpose :
  6. Zone : QeynosHarbor
  7. Quest Giver: Innkeeper Galsway (2210022)
  8. Preceded by: None
  9. Followed by:
  10. --]]
  11. function Init(Quest)
  12. AddQuestStepChat(Quest, 1, "Speak with Alissa Cleeway.", 1, "I need to speak with the four merchants at the \"Fisherman's Market\".", 0, 2210138)
  13. AddQuestStepChat(Quest, 2, "Speak with Aeris Lightwind.", 1, "I need to speak with the four merchants at the \"Fisherman's Market\".", 0, 2210049)
  14. AddQuestStepChat(Quest, 3, "Speak with Umli Grayfist.", 1, "I need to speak with the four merchants at the \"Fisherman's Market\".", 0, 2210135)
  15. AddQuestStepChat(Quest, 4, "Speak with Phen Domlinson.", 1, "I need to speak with the four merchants at the \"Fisherman's Market\".", 0, 2210147)
  16. AddQuestStepCompleteAction(Quest, 1, "Step1Alissa")
  17. AddQuestStepCompleteAction(Quest, 2, "Step2Aeris")
  18. AddQuestStepCompleteAction(Quest, 3, "Step3Umli")
  19. AddQuestStepCompleteAction(Quest, 4, "Step4Phen")
  20. end
  21. function Accepted(Quest, QuestGiver, Player)
  22. FaceTarget(QuestGiver, Player)
  23. conversation = CreateConversation()
  24. PlayFlavor(QuestGiver, "voiceover/english/innkeeper_galsway/qey_harbor/qst_innkeepergalsway001.mp3", "", "nod", 1195447184, 17037646, Player)
  25. AddConversationOption(conversation, "Alright. I'm off to the market.")
  26. StartConversation(conversation, QuestGiver, Player, "Well then, go to it!")
  27. end
  28. function Step1Alissa(Quest, QuestGiver, Player)
  29. UpdateQuestStepDescription(Quest, 1, "I've spoken with Alissa Cleeway.")
  30. CheckProgress(Quest, QuestGiver, Player)
  31. end
  32. function Step2Aeris(Quest, QuestGiver, Player)
  33. UpdateQuestStepDescription(Quest, 2, "I've spoken with Aeris Lightwind.")
  34. CheckProgress(Quest, QuestGiver, Player)
  35. end
  36. function Step3Umli(Quest, QuestGiver, Player)
  37. UpdateQuestStepDescription(Quest, 3, "I've spoken with Umli Grayfist.")
  38. CheckProgress(Quest, QuestGiver, Player)
  39. end
  40. function Step4Phen(Quest, QuestGiver, Player)
  41. UpdateQuestStepDescription(Quest, 4, "I've spoken with Phen Domlinson.")
  42. CheckProgress(Quest, QuestGiver, Player)
  43. end
  44. function CheckProgress(Quest, QuestGiver, Player)
  45. if QuestStepIsComplete(Player, 5564, 1) and QuestStepIsComplete(Player, 5564, 2) and QuestStepIsComplete(Player, 5564, 3) and QuestStepIsComplete(Player, 5564, 4) then
  46. UpdateQuestStepDescription(Quest, "I've spoken to all of the merchants only one offered a discount.")
  47. UpdateQuestTaskGroupDescription(Quest, 1, "I've spoken to all of the merchants only one offered a discount.")
  48. AddQuestStepChat(Quest, 5, "I need to return to Innkeeper Galsway at the Fish's Alehouse and Inn.", 1, "Innkeeper Galsway is waiting for me at the inn at Qeynos Harbor. He would be interested in my findings on the fish prices offered from the market.", 11, 2210022)
  49. AddQuestStepCompleteAction(Quest, 5, "QuestComplete")
  50. end
  51. end
  52. function Declined(Quest, QuestGiver, Player)
  53. end
  54. function QuestComplete(Quest, QuestGiver, Player)
  55. -- The following UpdateQuestStepDescription and UpdateTaskGroupDescription are not needed, parser adds them for completion in case stuff needs to be moved around
  56. UpdateQuestStepDescription(Quest, 5, "I spoke with Innkeeper Galsway.")
  57. UpdateQuestTaskGroupDescription(Quest, 2, "Innkeeper Galsway was pleased to hear about my findings at the market.")
  58. UpdateQuestDescription(Quest, "Galsway was pleased with the news of a five percent discount. He complimented me on my efforts, and made promises of future employment.")
  59. GiveQuestReward(Quest, Player)
  60. end
  61. function Reload(Quest, QuestGiver, Player, Step)
  62. if Step == 1 then
  63. Step1Alissa(Quest, QuestGiver, Player)
  64. elseif Step == 2 then
  65. Step2Aeris(Quest, QuestGiver, Player)
  66. elseif Step == 3 then
  67. Step3Umli(Quest, QuestGiver, Player)
  68. elseif Step == 4 then
  69. Step4Phen(Quest, QuestGiver, Player)
  70. elseif Step == 5 then
  71. QuestComplete(Quest, QuestGiver, Player)
  72. end
  73. end