9
3

sea_food_stew.lua 3.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384
  1. --[[
  2. Script Name : Quests/QeynosHarbor/sea_food_stew.lua
  3. Script Author : Dorbin
  4. Script Date : 2022.06.13 07:06:43
  5. Script Purpose :
  6. Zone : QeynosHarbor
  7. Quest Giver: Cordun Brenland
  8. Preceded by: None
  9. Followed by:
  10. --]]
  11. function Init(Quest)
  12. AddQuestStepKill(Quest, 1, "Kill two Coldwind barracudas.", 2, 100, "I need to head out into Antonica and get two barracuda, a manta ray and two sea turtles. I can probably find them south of the Qeynos docks.", 2541, 121238,120081)
  13. AddQuestStepKill(Quest, 2, "Kill two sea turtles.", 2, 100, "I need to head out into Antonica and get two barracuda, a manta ray and two sea turtles. I can probably find them south of the Qeynos docks.", 201, 120033,121212)
  14. AddQuestStepKill(Quest, 3, "Kill one Coldwind mantaray.", 1, 100, "I need to head out into Antonica and get two barracuda, a manta ray and two sea turtles. I can probably find them south of the Qeynos docks.", 86, 120084,121240)
  15. AddQuestStepCompleteAction(Quest, 1, "Step1Complete")
  16. AddQuestStepCompleteAction(Quest, 2, "Step2Complete")
  17. AddQuestStepCompleteAction(Quest, 3, "Step2Complete")
  18. UpdateQuestZone(Quest,"Antonica")
  19. end
  20. function Accepted(Quest, QuestGiver, Player)
  21. FaceTarget(QuestGiver, Player)
  22. local conversation = CreateConversation()
  23. AddConversationOption(conversation, "Okay! Okay, I'm going.")
  24. StartConversation(conversation, QuestGiver, Player, "Off with you then! I'm busy here planning my next move.")
  25. end
  26. function Declined(Quest, QuestGiver, Player)
  27. -- Add dialog here for when the quest is declined
  28. end
  29. function Deleted(Quest, QuestGiver, Player)
  30. -- Remove any quest specific items here when the quest is deleted
  31. end
  32. function Step1Complete(Quest, QuestGiver, Player)
  33. UpdateQuestStepDescription(Quest, 1, "I've caught two Coldwind barracuda.")
  34. CheckProgress(Quest, QuestGiver, Player)
  35. end
  36. function Step2Complete(Quest, QuestGiver, Player)
  37. UpdateQuestStepDescription(Quest, 2, "I've caught two sea turtles.")
  38. CheckProgress(Quest, QuestGiver, Player)
  39. end
  40. function Step3Complete(Quest, QuestGiver, Player)
  41. UpdateQuestStepDescription(Quest, 3, "I've caught a Coldwind mantaray.")
  42. CheckProgress(Quest, QuestGiver, Player)
  43. end
  44. function CheckProgress(Quest, QuestGiver, Player)
  45. if QuestStepIsComplete(Player, 5585, 1) and QuestStepIsComplete(Player, 5585, 2) and QuestStepIsComplete(Player, 5585, 3) then
  46. UpdateQuestTaskGroupDescription(Quest, 1, "I've killed the two barracuda, a manta ray and two sea turtles as Cordun requested.")
  47. UpdateQuestZone(Quest,"Qeynos Harbor")
  48. AddQuestStepChat(Quest, 4, "I need to deliver this sea food to Cordun Brenland.", 1, "Cordun Brenland in Qeynos Harbor is waiting for this sea food delivery.", 2541, 2210501)
  49. AddQuestStepCompleteAction(Quest, 4, "QuestComplete")
  50. end
  51. end
  52. function QuestComplete(Quest, QuestGiver, Player)
  53. -- The following UpdateQuestStepDescription and UpdateTaskGroupDescription are not needed, parser adds them for completion in case stuff needs to be moved around
  54. UpdateQuestTaskGroupDescription(Quest, 1, "I've delivered the sea food Cordun requested.")
  55. UpdateQuestStepDescription(Quest, 4, "I've returned to Cordun Brenland.")
  56. UpdateQuestDescription(Quest, "I've brought back the sea food catch and it turns out it was for a stew, though it wasn't intended to be shared with me.")
  57. GiveQuestReward(Quest, Player)
  58. end
  59. function Reload(Quest, QuestGiver, Player, Step)
  60. if Step == 1 then
  61. Step1Complete(Quest, QuestGiver, Player)
  62. elseif Step == 2 then
  63. Step2Complete(Quest, QuestGiver, Player)
  64. elseif Step == 3 then
  65. Step3Complete(Quest, QuestGiver, Player)
  66. elseif Step == 4 then
  67. CheckProgress(Quest, QuestGiver, Player)
  68. end
  69. end