9
3

a_good_distraction.lua 4.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687
  1. --[[
  2. Script Name : Quests/FrostfangSea/a_good_distraction.lua
  3. Script Purpose : for the quest "A Good Distraction"
  4. Script Author : theFoof
  5. Script Date : 2013.6.13
  6. Script Notes :
  7. Zone : Frostfang Sea
  8. Quest Giver : Thirin Veliumdelver
  9. Preceded by : Ry'Gorr Mining Operation
  10. Followed by : Sleetfoot Search Party
  11. --]]
  12. function Init(Quest)
  13. AddQuestRewardCoin(Quest, math.random(5,90), math.random(24,40), 0, 0)
  14. AddQuestStepChat(Quest, 1, "I should speak with Ordin Sleetfoot and begin our journey.", 1, "Thirin Veliumdelver wants me to speak with Ordin Sleetfoot when I am ready to venture into the Velinoid Catacombs.", 0, 4700965)
  15. AddQuestStepCompleteAction(Quest, 1, "TalkedOrdin")
  16. end
  17. function Accepted(Quest, QuestGiver, Player)
  18. FaceTarget(QuestGiver, Player)
  19. conversation = CreateConversation()
  20. PlayFlavor(QuestGiver, "thirin_veliumdelver/halas/cragged_spine/thirin_veliumdelver_cave010.mp3", "", "", 2867242801, 3355205024, Player)
  21. AddConversationOption(conversation, "I will.")
  22. StartConversation(conversation, QuestGiver, Player, "I am learning that with each passing hour. Be safe, my friend.")
  23. end
  24. function Deleted(Quest, QuestGiver, Player)
  25. local zone = GetZone(Player)
  26. if GetZoneID == 470 then
  27. AddSpawnAccess(GetSpawnByLocationID(zone, 32643), Player)
  28. end
  29. end
  30. function Declined(Quest, QuestGiver, Player)
  31. end
  32. function TalkedOrdin(Quest, QuestGiver, Player)
  33. UpdateQuestTaskGroupDescription(Quest, 1, "I have spoken with Ordin, who has vanished into the shadows.")
  34. AddQuestStep(Quest, 2, "I should travel deeper into the Velinoid Catacombs and seek out Ordin.", 1, 100, "I should travel into the Velinoid Catacombs and act as a distraction so none of the Velinoids discover Ordin. He says I will eventually find him as I travel through the cavern.", 0)
  35. AddQuestStepCompleteAction(Quest, 2, "KilledVelinoids")
  36. end
  37. function KilledVelinoids(Quest, QuestGiver, Player)
  38. UpdateQuestStepDescription(Quest, 2, "Ordin was attacked by Velinoids but I was able to fend them off.")
  39. AddQuestStepChat(Quest, 3, "I should make sure that Ordin is okay before continuing on.", 1, "I should travel into the Velinoid Catacombs and act as a distraction so none of the Velinoids discover Ordin. He says I will eventually find him as I travel through the cavern.", 0, 4700965)
  40. AddQuestStepCompleteAction(Quest, 3, "FoundOrdin")
  41. end
  42. function FoundOrdin(Quest, QuestGiver, Player)
  43. UpdateQuestStepDescription(Quest, 3, "Ordin is fine and has returned to the shadows.")
  44. UpdateQuestTaskGroupDescription(Quest, 2, "Ordin has returned to the shadows and wants to continue exploring the catacombs. I imagine I'll find him again further in.")
  45. AddQuestStep(Quest, 4, "I should travel deeper into the Velinoid Catacombs and seek out Ordin.", 1, 100, "I should travel further into the Velinoid Catacombs, continuing to act as a distraction for Ordin. As before I will find him as I travel futher into the catacombs.", 0)
  46. AddQuestStepCompleteAction(Quest, 4, "KilledAmbush")
  47. end
  48. function KilledAmbush(Quest, QuestGiver, Player)
  49. UpdateQuestStepDescription(Quest, 4, "Ordin was attacked by Velinoids but I was able to fend them off.")
  50. AddQuestStepChat(Quest, 5, "I should make sure that Ordin is okay before continuing on.", 1, "I should travel further into the Velinoid Catacombs, continuing to act as a distraction for Ordin. As before I will find him as I travel futher into the catacombs.", 0, 4700965)
  51. AddQuestStepCompleteAction(Quest, 5, "FoundOrdin2")
  52. end
  53. function FoundOrdin2(Quest, QuestGiver, Player)
  54. UpdateQuestStepDescription(Quest, 5, "Ordin is fine and has instructed me to return to Thirin Veliumdelver.")
  55. UpdateQuestTaskGroupDescription(Quest, 3, "While Ordin is checking out one last section of the catacombs, he has instructed me to return to Thirin Veliumdelver at the cavern's entrance.")
  56. AddQuestStepChat(Quest, 6, "I should speak with Thirin Veliumdelver.", 1, "I should return to Thirin Veliumdelver, as Ordin instructed, and tell him the layout of the catacombs. Ordin should be waiting for me there if he's as good a scout as claimed.", 0, 4700112)
  57. AddQuestStepCompleteAction(Quest, 6, "CompleteQuest")
  58. end
  59. function CompleteQuest(Quest, QuestGiver, Player)
  60. GiveQuestReward(Quest, Player)
  61. end
  62. function Reload(Quest, QuestGiver, Player, Step)
  63. if Step == 1 then
  64. TalkedOrdin(Quest, QuestGiver, Player)
  65. elseif Step == 2 then
  66. KilledVelinoids(Quest, QuestGiver, Player)
  67. elseif Step == 3 then
  68. FoundOrdin(Quest, QuestGiver, Player)
  69. elseif Step == 4 then
  70. KilledAmbush(Quest, QuestGiver, Player)
  71. elseif Step == 5 then
  72. FoundOrdin2(Quest, QuestGiver, Player)
  73. end
  74. end