free_wares_for_silentblade.lua 2.8 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061
  1. --[[
  2. Script Name : free_wares_for_silentblade.lua
  3. Script Purpose : Handles the quest, "Free Wares for Silentblade"
  4. Script Author : torsten\\Dorbin
  5. Script Date : 15.07.2022
  6. Script Notes :
  7. Zone : Beggar's Court
  8. Quest Giver : Armsdealer Silentblade
  9. Preceded by : None
  10. Followed by : Get Rich Quick!
  11. --]]
  12. require "SpawnScripts/Generic/DialogModule"
  13. function Init(Quest)
  14. AddQuestStepKill(Quest, 1, "I must kill undead battlepriests and collect ten maces.", 10, 100, "I should head over to the Graveyard and collect ten maces from undead battlepriests.", 34, 1250008, 1250018)
  15. AddQuestStepCompleteAction(Quest, 1, "Step1Complete")
  16. UpdateQuestZone(Quest,"The Graveyard")
  17. end
  18. function Step1Complete(Quest, QuestGiver, Player)
  19. UpdateQuestStepDescription(Quest, 1, "I've collected the maces from the battlepriests.")
  20. UpdateQuestTaskGroupDescription(Quest, 1, "I've killed the undead battlepriests and searched through their remains. I've managed to collect ten maces from their bones.")
  21. UpdateQuestZone(Quest,"Beggar's Court")
  22. AddQuestStepChat(Quest, 2, "I need to speak with Silentblade.", 1, "I should bring these maces back to Silentblade in Beggar's Court.", 34, 1370011)
  23. AddQuestStepCompleteAction(Quest, 2, "QuestComplete")
  24. end
  25. function QuestComplete(Quest, QuestGiver, Player)
  26. UpdateQuestStepDescription(Quest, 2, "I returned to Silentblade.")
  27. UpdateQuestTaskGroupDescription(Quest, 2, "I have given Arms Dealer Silentblade all of the maces I've collected.")
  28. UpdateQuestDescription(Quest, "Silentblade showed me that one of his secrets was to collect up old rusty weapons from the undead. Soaking the weapons in acid and giving them a new coat of paint make them look brand new. I'm not sure I would ever buy anything from him if I wanted to live longer than my next battle.")
  29. GiveQuestReward(Quest, Player)
  30. end
  31. function Accepted(Quest, QuestGiver, Player)
  32. FaceTarget(QuestGiver, Player)
  33. Dialog.New(QuestGiver, Player)
  34. Dialog.AddDialog("Okay, kid, this is what I need. I'm running out of maces, so I need you to gather up more. Go out to the Graveyard and destroy all of the Undead Priests you find. Most of them carry a mace. Destroy the priests, then bring me their maces.")
  35. Dialog.AddVoiceover("voiceover/english/armsdealer_silentblade/fprt_hood04/quests/armsdealersilentblade/silentblade_x1_accept.mp3", 3601742052, 613995562)
  36. Dialog.AddOption("Maces. Got it.")
  37. Dialog.Start()
  38. end
  39. function Declined(Quest, QuestGiver, Player)
  40. -- Add dialog here for when the quest is declined
  41. end
  42. function Deleted(Quest, QuestGiver, Player)
  43. -- Remove any quest specific items here when the quest is deleted
  44. end
  45. function Reload(Quest, QuestGiver, Player, Step)
  46. if Step == 1 then
  47. Step1Complete(Quest, QuestGiver, Player)
  48. elseif Step == 2 then
  49. QuestComplete(Quest, QuestGiver, Player)
  50. end
  51. end