edgewater_needletooth_pudding.lua 4.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100
  1. --[[
  2. Script Name : Quests/EdgewaterDrains/edgewater_needletooth_pudding.lua
  3. Script Purpose : Handles the quest, "Edgewater Needletooth Pudding"
  4. Script Author : premierio015
  5. Script Date : 05.07.2021
  6. Script Notes : Auto generated with QuestParser.
  7. Zone : Edgewater Drains
  8. Quest Giver :
  9. Preceded by : None
  10. Followed by : None
  11. --]]
  12. function Init(Quest)
  13. SetQuestFeatherColor(Quest, 3)
  14. SetQuestRepeatable(Quest)
  15. AddQuestStepKill(Quest, 1, "Recipe calls for four young serpent skins. Young sewage vipers should be just what I need.", 4, 100, "All of the ingredients I need for the \"Needletooth Pudding\" are here in the Edgewater Drains.", 98, 1560026)
  16. AddQuestStepKill(Quest, 2, "Recipe calls for ten crab legs.", 10, 100, "All of the ingredients I need for the \"Needletooth Pudding\" are here in the Edgewater Drains.", 76, 1560018, 1560009)
  17. AddQuestStepKill(Quest, 3, "Recipe calls for a dozen Needletooth teeth.", 12, 100, "All of the ingredients I need for the \"Needletooth Pudding\" are here in the Edgewater Drains.", 112, 1560022 )
  18. AddQuestStepKill(Quest, 4, "Recipe calls for five turtle shells.", 5, 100, "All of the ingredients I need for the \"Needletooth Pudding\" are here in the Edgewater Drains.", 201, 1560034)
  19. AddQuestStepKill(Quest, 5, "Recipe calls for five frantic globules, but any goo will do.", 5, 100, "All of the ingredients I need for the \"Needletooth Pudding\" are here in the Edgewater Drains.", 355, 1560001, 1560091, 1560011, 1560011 )
  20. AddQuestStepCompleteAction(Quest, 1, "Step1Complete")
  21. AddQuestStepCompleteAction(Quest, 2, "Step2Complete")
  22. AddQuestStepCompleteAction(Quest, 3, "Step3Complete")
  23. AddQuestStepCompleteAction(Quest, 4, "Step4Complete")
  24. AddQuestStepCompleteAction(Quest, 5, "Step5Complete")
  25. end
  26. function Accepted(Quest, QuestGiver, Player)
  27. -- Add dialog here for when the quest is accepted
  28. end
  29. function Declined(Quest, QuestGiver, Player)
  30. -- Add dialog here for when the quest is declined
  31. end
  32. function Deleted(Quest, QuestGiver, Player)
  33. -- Remove any quest specific items here when the quest is deleted
  34. end
  35. function Step1Complete(Quest, QuestGiver, Player)
  36. UpdateQuestStepDescription(Quest, 1, "I've got another young serpent skin.")
  37. CheckProgress(Quest, QuestGiver, Player)
  38. end
  39. function Step2Complete(Quest, QuestGiver, Player)
  40. UpdateQuestStepDescription(Quest, 2, "I've got another crab leg.")
  41. CheckProgress(Quest, QuestGiver, Player)
  42. end
  43. function Step3Complete(Quest, QuestGiver, Player)
  44. UpdateQuestStepDescription(Quest, 3, "I've got another Needletooth tooth.")
  45. CheckProgress(Quest, QuestGiver, Player)
  46. end
  47. function Step4Complete(Quest, QuestGiver, Player)
  48. UpdateQuestStepDescription(Quest, 4, "I've got another turtle shell.")
  49. CheckProgress(Quest, QuestGiver, Player)
  50. end
  51. function Step5Complete(Quest, QuestGiver, Player)
  52. UpdateQuestStepDescription(Quest, 5, "I've got another goo.")
  53. CheckProgress(Quest, QuestGiver, Player)
  54. end
  55. function QuestComplete(Quest, QuestGiver, Player)
  56. -- The following UpdateQuestStepDescription and UpdateTaskGroupDescription are not needed, parser adds them for completion in case stuff needs to be moved around
  57. UpdateQuestTaskGroupDescription(Quest, 1, "I've gathered all of the ingredients for the \"Needletooth Pudding\" but the fact that all of the ingredients came from a sewer... I don't know.")
  58. if HasItem(Player, 10028) then
  59. RemoveItem(Player, 10028)
  60. end
  61. UpdateQuestDescription(Quest, "I've gathered all of the ingredients needed for the this \"Needletooth Pudding\" but actually eating it, now that's another story.")
  62. GiveQuestReward(Quest, Player)
  63. end
  64. function CheckProgress(Quest, QuestGiver, Player)
  65. if QuestStepIsComplete(Player, 5300, 1) and QuestStepIsComplete(Player, 5300, 2) and QuestStepIsComplete(Player, 5300, 3) and QuestStepIsComplete(Player, 5300, 4) and QuestStepIsComplete(Player, 5300, 5) then
  66. QuestComplete(Quest, QuestGiver, Player)
  67. end
  68. end
  69. function Reload(Quest, QuestGiver, Player, Step)
  70. if Step == 1 then
  71. Step1Complete(Quest, QuestGiver, Player)
  72. elseif Step == 2 then
  73. Step2Complete(Quest, QuestGiver, Player)
  74. elseif Step == 3 then
  75. Step3Complete(Quest, QuestGiver, Player)
  76. elseif Step == 4 then
  77. Step4Complete(Quest, QuestGiver, Player)
  78. elseif Step == 5 then
  79. Step5Complete(Quest, QuestGiver, Player)
  80. end
  81. end