a_shady_clearing.lua 2.9 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061
  1. --[[
  2. Script Name : a_shady_clearing.lua
  3. Script Purpose : Handles the quest, "A Shady Clearing"
  4. Script Author : torsten
  5. Script Date : 19.07.2022
  6. Script Notes :
  7. Zone : Longshadow Alley
  8. Quest Giver : Imnat D`Vren
  9. Preceded by : A Dramatic Performance
  10. Followed by : None
  11. --]]
  12. require "SpawnScripts/Generic/DialogModule"
  13. function Init(Quest)
  14. AddQuestStepKill(Quest, 1, "I must kill ten diseased ratonga", 10, 100, " I need to venture to the sewers and kill ten diseased ratonga", 611, 1540002, 1540021, 1540022, 1540024, 1540028, 1540072, 1540073)
  15. AddQuestStepCompleteAction(Quest, 1, "Step1Complete")
  16. UpdateQuestZone(Quest,"Thieves Way")
  17. end
  18. function Step1Complete(Quest, QuestGiver, Player)
  19. UpdateQuestStepDescription(Quest, 1, "I have killed ten diseased ratonga.")
  20. UpdateQuestTaskGroupDescription(Quest, 1, "I've killed ten of the diseased ratonga and made sure the way is clear for Imnat's treasure.")
  21. UpdateQuestZone(Quest,"Longshadow Alley")
  22. AddQuestStepChat(Quest, 2, "I should return to Imnat D`Vren.", 1, "I should return to Imnat D`Vren in Longshadow Alley.", 11, 1380031)
  23. AddQuestStepCompleteAction(Quest, 2, "QuestComplete")
  24. end
  25. function QuestComplete(Quest, QuestGiver, Player)
  26. UpdateQuestStepDescription(Quest, 2, "I've informed Imnat that sewers have less diseased ratonga.")
  27. UpdateQuestTaskGroupDescription(Quest, 2, "I've informed Imnat that sewers have a few less diseased ratonga to get in the way.")
  28. UpdateQuestDescription(Quest, "I've cleared the way for Imnat's treasure to show up. I'm not sure what this is all about, but it feels rather important. Imnat said that in time I may be told more about how this treasure will 'liberate' the Teir'Dal from Lucan's grasp.")
  29. GiveQuestReward(Quest, Player)
  30. end
  31. function Accepted(Quest, QuestGiver, Player)
  32. FaceTarget(QuestGiver, Player)
  33. Dialog.New(QuestGiver, Player)
  34. Dialog.AddDialog("We're giving Pavo Nightfire another chance to make up for his past failure. You killed the raiders hired by Pavo to ensure an invaluable treasure made it safely into our hands. His attempt met with dismal failure, but this will not dissuade us from trying to transport the treasure again. Before we attempt another delivery, we need to clear the sewers of the diseased refugees who live there. Go and kill some of these ailing peasants and return.")
  35. PlayFlavor(QuestGiver,"","","agree",0,0,Player)
  36. Dialog.AddOption("For treasure's sake, I will purge the sewers of this refuse!")
  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