9
3

a_package.lua 2.8 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667
  1. --[[
  2. Script Name : Quests/Graystone/a_package.lua
  3. Script Purpose : Handles the quest, "A Package"
  4. Script Author : Scatman
  5. Script Date : 2009.10.05
  6. Zone : Graystone Yard
  7. Quest Giver: Mav Boilfist
  8. Preceded by: Cheers! (cheers.lua)
  9. Followed by: A Stone From Home (a_stone_from_home.lua)
  10. --]]
  11. function Init(Quest)
  12. AddQuestStepChat(Quest, 1, "I need to speak with the shipping coordinator on the docks.", 1, "I need to get Mav's package for her.", 0, 2350004)
  13. AddQuestStepCompleteAction(Quest, 1, "Step1_Complete_SpokeWithShippingCoordinator")
  14. end
  15. function Accepted(Quest, QuestGiver, Player)
  16. FaceTarget(QuestGiver, Player)
  17. conversation = CreateConversation()
  18. PlayFlavor(QuestGiver, "voiceover/english/tutorial_revamp/mav_boilfist/qey_village03/quests/mav_boilfist/mav_boilfist023.mp3", "", "", 3437868051, 3538588348, Player)
  19. AddConversationOption(conversation, "I'll be right back.")
  20. StartConversation(conversation, QuestGiver, Player, "Oh you're simply too sweet to be a dwarf. Thanks.")
  21. end
  22. function Declined(Quest, QuestGiver, Player)
  23. end
  24. function Step1_Complete_SpokeWithShippingCoordinator(Quest, QuestGiver, Player)
  25. UpdateQuestStepDescription(Quest, 1, "I have spoken with the shipping coordinator.")
  26. AddQuestStep(Quest, 2, "I need to check the crates down at the end of the docks and see if any of them have Mav's package.", 1, 100, "I need to get Mav's package for her.", 0)
  27. AddQuestStepCompleteAction(Quest, 2, "Step2_Complete_FoundMavsPackage")
  28. end
  29. function Step2_Complete_FoundMavsPackage(Quest, QuestGiver, Player)
  30. UpdateQuestStepDescription(Quest, 2, "I have found Mav's package.")
  31. AddQuestStepChat(Quest, 3, "I need to clear this package with the shipping coordinator.", 1, "I need to get Mav's package for her.", 0, 2350004)
  32. AddQuestStepCompleteAction(Quest, 3, "Step3_Complete_SpokeWithShippingCoordinator")
  33. end
  34. function Step3_Complete_SpokeWithShippingCoordinator(Quest, QuestGiver, Player)
  35. UpdateQuestStepDescription(Quest, 3, "I have cleared this package.")
  36. AddQuestStepChat(Quest, 4, "I need to deliver Mav's package to her.", 1, "I need to get Mav's package for her.", 0, 2350016)
  37. AddQuestStepCompleteAction(Quest, 4, "Quest_Complete")
  38. end
  39. function Quest_Complete(Quest, QuestGiver, Player)
  40. UpdateQuestStepDescription(Quest, 4, "I have delivered Mav's package.")
  41. UpdateQuestTaskGroupDescription(Quest, 1, "I have given Mav her package.")
  42. GiveQuestReward(Quest, Player)
  43. UpdateQuestDescription(Quest, "I have collected Mav's package for her.")
  44. end
  45. function Reload(Quest, QuestGiver, Player, Step)
  46. if Step == 1 then
  47. Step1_Complete_SpokeWithShippingCoordinator(Quest, QuestGiver, Player)
  48. elseif Step == 2 then
  49. Step2_Complete_FoundMavsPackage(Quest, QuestGiver, Player)
  50. elseif Step == 3 then
  51. Step3_Complete_SpokeWithShippingCoordinator(Quest, QuestGiver, Player)
  52. end
  53. end