9
3

charge_of_the_leatherfoot_brigade__frambert.lua 4.0 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576
  1. --[[
  2. Script Name : Quests/FallenGate/charge_of_the_leatherfoot_brigade__frambert.lua
  3. Script Purpose : Handles the quest, "Charge of the Leatherfoot Brigade - Frambert"
  4. Script Author : premierio015
  5. Script Date : 10.07.2021
  6. Script Notes : Auto generated with QuestParser.
  7. Zone : Fallen Gate
  8. Quest Giver : The Sarge
  9. Preceded by : None
  10. Followed by : None
  11. --]]
  12. function Init(Quest)
  13. AddQuestStep(Quest, 1, "I need to smash the first alarm in the marketplace.", 1, 100, "Frambert's duty was to find two separate "alarms" in the marketplaces, possibly in the important looking buildings. I can only hope these alarms are still around after all these years.", 11)
  14. AddQuestStep(Quest, 2, "I need to smash the second alarm in the marketplace.", 1, 100, "Frambert's duty was to find two separate "alarms" in the marketplaces, possibly in the important looking buildings. I can only hope these alarms are still around after all these years.", 11)
  15. AddQuestStepCompleteAction(Quest, 1, "Step1Complete")
  16. AddQuestStepCompleteAction(Quest, 2, "Step2Complete")
  17. end
  18. function Accepted(Quest, QuestGiver, Player)
  19. FaceTarget(QuestGiver, Player)
  20. local conversation = CreateConversation()
  21. PlayFlavor(QuestGiver, "voiceover/english/the_sarge/fallengate/qst_the_sarge008.mp3", "", "", 2152925138, 1149927317, Player)
  22. AddConversationOption(conversation, "This happened hundred of years ago, ghost! It won't matter if... fine. I'll do it.")
  23. StartConversation(conversation, QuestGiver, Player, "That's the spirit, kid! Now listen close. These dark elves have magical contraptions that can alert the guards on the double. We're gonna make a mad dash to drop the whatchamacallit right in the market, but if they know we're chargin'... well, we won't get too far. You gotta smash these things, got it? Check them big buildings... they probably keep 'em there.")
  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, "I've tried smashing one of the alarms, but it was magically protected.")
  33. CheckProgress(Quest, QuestGiver, Player)
  34. end
  35. function Step2Complete(Quest, QuestGiver, Player)
  36. UpdateQuestStepDescription(Quest, 2, "I've tried smashing one of the alarms, but it was magically protected.")
  37. CheckProgress(Quest, QuestGiver, Player)
  38. end
  39. function QuestComplete(Quest, QuestGiver, Player)
  40. -- The following UpdateQuestStepDescription and UpdateTaskGroupDescription are not needed, parser adds them for completion in case stuff needs to be moved around
  41. UpdateQuestStepDescription(Quest, 3, "I've spoken with the Sarge's ghost")
  42. UpdateQuestTaskGroupDescription(Quest, 2, "I've spoken with the Sarge again, and I doubt he'll ever pay attention to the fact that I'm not part of his brigade.")
  43. UpdateQuestDescription(Quest, "I've tried smashing the alarms like Frambert was supposed to do, but was unable to do so.")
  44. GiveQuestReward(Quest, Player)
  45. end
  46. function CheckProgress(Quest, QuestGiver, Player)
  47. if QuestStepIsComplete(Player, 5310, 1) and QuestStepIsComplete(Player, 5310, 2) then
  48. AddQuestStepChat(Quest, 3, "I need to speak with the Sarge's ghost", 1, "Since the alarms weren't destroyed, I can only assume that Frambert was as unsuccessful as I was. I should return to the Sarge and see if he has anything else to say", 11, 1190020)
  49. AddQuestStepCompleteAction(Quest, 3, "QuestComplete")
  50. UpdateQuestTaskGroupDescription(Quest, 1, "I've tried smashing the alarms, but they seemed to be invulnerable even after all these years.")
  51. end
  52. end
  53. function Reload(Quest, QuestGiver, Player, Step)
  54. if Step == 1 then
  55. Step1Complete(Quest, QuestGiver, Player)
  56. elseif Step == 2 then
  57. Step2Complete(Quest, QuestGiver, Player)
  58. elseif Step == 3 then
  59. QuestComplete(Quest, QuestGiver, Player)
  60. end
  61. end