there_mite_be_trouble.lua 2.4 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162
  1. --[[
  2. Script Name : there_mite_be_trouble.lua
  3. Script Purpose : Handles the quest, "There Mite be Trouble"
  4. Script Author : geordie0511
  5. Script Date : 12.03.2019
  6. Script Notes : Edited by geordie0511
  7. Zone : Antonica
  8. Quest Giver : Farmer Walcott
  9. Preceded by : None
  10. Followed by : None
  11. --]]
  12. require "SpawnScripts/Generic/DialogModule"
  13. function Init(Quest)
  14. AddQuestStepKill(Quest, 1, "Slay some klicnik mites.", 10, 100, "I need to slay 10 klicnik mites in the crops outside of the North Gates of Qeynos.", 611, 120067, 121225)
  15. AddQuestStepCompleteAction(Quest, 1, "Step1Complete")
  16. end
  17. function Accepted(Quest, QuestGiver, Player)
  18. FaceTarget(QuestGiver, Player)
  19. Dialog.New(QuestGiver, Player)
  20. Dialog.AddDialog("Thank the lost gods! I know you can't exterminate all these pests, but please do your best. I'll reward you with what I can. Don't worry, little barley ... help is on the way.")
  21. Dialog.AddVoiceover("voiceover/english/farmer_walcott/antonica/farmerwalcott002.mp3", 1854564329, 3891746852)
  22. Dialog.AddOption("I will end your mite problems.")
  23. Dialog.Start()
  24. end
  25. function Declined(Quest, QuestGiver, Player)
  26. -- Add dialog here for when the quest is declined
  27. end
  28. function Deleted(Quest, QuestGiver, Player)
  29. -- Remove any quest specific items here when the quest is deleted
  30. end
  31. function Step1Complete(Quest, QuestGiver, Player)
  32. UpdateQuestStepDescription(Quest, 1, "Slew some klicnik mites.")
  33. UpdateQuestTaskGroupDescription(Quest, 1, "I slew 10 of the klicnik mites in Antonica.")
  34. AddQuestStepChat(Quest, 2, "Speak to Farmer Walcott.", 1, "I need to return to Farmer Walcott in Antonica.", 11, 120078)
  35. AddQuestStepCompleteAction(Quest, 2, "QuestComplete")
  36. end
  37. function QuestComplete(Quest, QuestGiver, Player)
  38. -- The following UpdateQuestStepDescription and UpdateTaskGroupDescription are not needed, parser adds them for completion in case stuff needs to be moved around
  39. UpdateQuestStepDescription(Quest, 2, "Spoke to Farmer Walcott.")
  40. UpdateQuestTaskGroupDescription(Quest, 2, "I returned to Farmer Walcott.")
  41. UpdateQuestDescription(Quest, "I have slain a number of the pesky klicnik mites that plagued the crops of Farmer Walcott outside of the North Gates of Qeynos.")
  42. GiveQuestReward(Quest, Player)
  43. end
  44. function Reload(Quest, QuestGiver, Player, Step)
  45. if Step == 1 then
  46. Step1Complete(Quest, QuestGiver, Player)
  47. elseif Step == 2 then
  48. QuestComplete(Quest, QuestGiver, Player)
  49. end
  50. end