proving_myself_to_captain_gerathalas.lua 2.7 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162
  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. function Init(Quest)
  12. 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)
  13. AddQuestStepCompleteAction(Quest, 1, "RatHunted")
  14. UpdateQuestZone(Quest, "The Down Below")
  15. end
  16. function Accepted(Quest, QuestGiver, Player)
  17. FaceTarget(NPC, Spawn)
  18. Dialog.New(NPC, Spawn)
  19. 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.")
  20. Dialog.AddVoiceover("voiceover/english/knight-captain_gerathalas/qey_village04/captaingerathalas001.mp3",1809197225,35106101)
  21. PlayFlavor(NPC, "", "", "agree", 0,0 , Spawn)
  22. Dialog.AddOption("Great, I'll be right back to prove how well I can take care of myself.")
  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 RatHunted(Quest, QuestGiver, Player)
  32. -- The following UpdateQuestStepDescription and UpdateTaskGroupDescription are not needed, parser adds them for completion in case stuff needs to be moved around
  33. UpdateQuestStepDescription(Quest, 1, "I have killed some putrid vermin.")
  34. UpdateQuestTaskGroupDescription(Quest, 1, "I collected the six putrid vermin tails that Captain Gerathalas wanted.")
  35. UpdateQuestZone(Quest, "Castleview Hamlet")
  36. 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)
  37. AddQuestStepCompleteAction(Quest, 2, "QuestComplete")
  38. end
  39. function QuestComplete(Quest, QuestGiver, Player)
  40. UpdateQuestStepDescription(Quest, 2, "I returned to Gerathalas.")
  41. UpdateQuestTaskGroupDescription(Quest, 2, "I've given proof to Captain Gerathalas proving I've delt with the putrid vermin.")
  42. 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.")
  43. GiveQuestReward(Quest, Player)
  44. end
  45. function Reload(Quest, QuestGiver, Player, Step)
  46. if Step == 1 then
  47. RatHunted(Quest, QuestGiver, Player)
  48. end
  49. if Step == 2 then
  50. QuestComplete(Quest, QuestGiver, Player)
  51. end
  52. end