BogSludgeHunt.lua 2.0 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253
  1. --[[
  2. Script Name : BogSludgeHunt.lua
  3. Script Purpose : Handles the quest, "Bog Sludge Hunt"
  4. Script Author : Shatou
  5. Script Date : 1/8/2020
  6. Script Notes :
  7. Zone : Peat Bog
  8. Quest Giver : Knight-Captain Santis
  9. Preceded by : None
  10. Followed by : None
  11. --]]
  12. local BOG_SLUDGE_ID = 1980002
  13. local KNIGHT_CAPTAIN_SANTIS_ID = 1980028
  14. function Init(Quest)
  15. AddQuestStepKill(Quest, 1, "I must kill several bog sludges", 10, 100, "I need to kill Bog Sludges in the Peat Bog.", 346, BOG_SLUDGE_ID)
  16. AddQuestStepCompleteAction(Quest, 1, "Step1Complete")
  17. end
  18. function Step1Complete(Quest, QuestGiver, Player)
  19. UpdateQuestStepDescription(Quest, 1, "I have killed the bog sludges.")
  20. UpdateQuestTaskGroupDescription(Quest, 1, "I have slain several Bog Sludges in the Peat Bog.")
  21. AddQuestStepChat(Quest, 2, "I need to return to Captain Santis.", 1, "I should return to Captain Santis for my reward.", 11, KNIGHT_CAPTAIN_SANTIS_ID)
  22. AddQuestStepCompleteAction(Quest, 2, "QuestComplete")
  23. end
  24. function QuestComplete(Quest, QuestGiver, Player)
  25. -- The following UpdateQuestStepDescription and UpdateTaskGroupDescription are not needed, parser adds them for completion in case stuff needs to be moved around
  26. UpdateQuestStepDescription(Quest, 2, "I spoke to Captain Santis.")
  27. UpdateQuestTaskGroupDescription(Quest, 2, "I received my reward for defeating the Bog Sludges.")
  28. UpdateQuestDescription(Quest, "I was able to make the Peat Bog a little safer for others by getting rid of several Bog Sludges. I also made a little coin on the side thanks to the payment from Captain Santis.")
  29. GiveQuestReward(Quest, Player)
  30. end
  31. function Reload(Quest, QuestGiver, Player, Step)
  32. if Step == 1 then
  33. Step1Complete(Quest, QuestGiver, Player)
  34. elseif Step == 2 then
  35. QuestComplete(Quest, QuestGiver, Player)
  36. end
  37. end
  38. function Accepted(Quest, QuestGiver, Player)
  39. -- Add dialog here for when the quest is accepted
  40. end
  41. function Declined(Quest, QuestGiver, Player)
  42. -- Add dialog here for when the quest is declined
  43. end