proving_myself_to_captain_gerathalas.lua 2.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263
  1. --[[
  2. Script Name : Quests/CastleviewHamlet/proving_myself_to_captain_gerathalas.lua
  3. Script Author : Dorbin
  4. Script Date : 2022.01.27 09:01:04
  5. Script Purpose :
  6. Zone : CastleviewHamlet
  7. Quest Giver: Captain Gerathalas
  8. Preceded by: None
  9. Followed by:
  10. --]]
  11. require "SpawnScripts/Generic/DialogModule"
  12. function Init(Quest)
  13. AddQuestStepKill(Quest, 1, "I must kill some putrid vermin.", 6, 100, "I need to collect six putrid vermin tails for Captain Gerathalas from the Catacombs.", 99, 1990008, 1990010,8340033,8340041)
  14. AddQuestStepCompleteAction(Quest, 1, "RatHunted")
  15. UpdateQuestZone(Quest, "The Down Below")
  16. end
  17. function Accepted(Quest, QuestGiver, Player)
  18. FaceTarget(QuestGiver, Player)
  19. Dialog.New(QuestGiver, Player)
  20. Dialog.AddDialog("Good, good! The vermin live in the catacombs. Bring me back some of those putrid rat's tails and I'll reward you with a piece of armor.")
  21. Dialog.AddVoiceover("voiceover/english/knight-captain_gerathalas/qey_village04/captaingerathalas001.mp3",1809197225,35106101)
  22. PlayFlavor(QuestGiver, "", "", "agree", 0,0 , Player)
  23. Dialog.AddOption("Great, I'll be right back to prove how well I can take care of myself.")
  24. Dialog.Start()
  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 RatHunted(Quest, QuestGiver, Player)
  33. -- The following UpdateQuestStepDescription and UpdateTaskGroupDescription are not needed, parser adds them for completion in case stuff needs to be moved around
  34. UpdateQuestStepDescription(Quest, 1, "I have killed some putrid vermin.")
  35. UpdateQuestTaskGroupDescription(Quest, 1, "I collected the six putrid vermin tails that Captain Gerathalas wanted.")
  36. UpdateQuestZone(Quest, "Castleview Hamlet")
  37. AddQuestStepChat(Quest, 2, "I must return to Knight-Captain Gerathalas.", 1, "I need to collect six putrid vermin tails for Captain Gerathalas from the Catacombs.", 99, 2360031)
  38. AddQuestStepCompleteAction(Quest, 2, "QuestComplete")
  39. end
  40. function QuestComplete(Quest, QuestGiver, Player)
  41. UpdateQuestStepDescription(Quest, 2, "I returned to Gerathalas.")
  42. UpdateQuestTaskGroupDescription(Quest, 2, "I've given proof to Captain Gerathalas proving I've delt with the putrid vermin.")
  43. UpdateQuestDescription(Quest, "I completed the task of collecting 6 putrid vermin tails for Captain Gerathalas. He seemed quite pleased with how well I did. He rewarded me with a piece of armor.")
  44. GiveQuestReward(Quest, Player)
  45. end
  46. function Reload(Quest, QuestGiver, Player, Step)
  47. if Step == 1 then
  48. RatHunted(Quest, QuestGiver, Player)
  49. end
  50. if Step == 2 then
  51. QuestComplete(Quest, QuestGiver, Player)
  52. end
  53. end