nylaspiethief.lua 3.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384
  1. --[[
  2. Script Name : Quests/Baubbleshire/nylas_pie_thief.lua
  3. Script Author : Dorbin
  4. Script Date : 2022.01.11 01:01:26
  5. Script Purpose :
  6. Zone : Baubbleshire
  7. Quest Giver: Nyla Diggs
  8. Preceded by: None
  9. Followed by:
  10. --]]
  11. function Init(Quest)
  12. AddQuestStepZoneloc(Quest, 1, "I must check 'The Ringing Hammer' smithy.", 5, "I need to check the smithy for someone who may have taken the pie", 0, 850.34, -18.22, -514.64, 238)
  13. AddQuestStepCompleteAction(Quest, 1, "step1beentothesmithy")
  14. end
  15. function Accepted(Quest, QuestGiver, Player)
  16. FaceTarget(QuestGiver, Spawn)
  17. conversation = CreateConversation()
  18. AddConversationOption(conversation, "I'll be back once I look around!")
  19. StartConversation(conversation, NPC, Spawn, "You'd do that? Tell you what - you search for the missing pie and when you return I'll have a fresh baked pie waiting for you. I'll give the culprit such a scolding they'll think twice before taking one of my pies.")
  20. end
  21. function Declined(Quest, QuestGiver, Player)
  22. end
  23. function Deleted(Quest, QuestGiver, Player)
  24. end
  25. function step1beentothesmithy(Quest, QuestGiver, Player)
  26. UpdateQuestStepDescription(Quest, 1, "I checked 'The Ringing Hammer'")
  27. UpdateQuestTaskGroupDescription(Quest, 1, "I checked the smithy, but found no one who took the pie")
  28. AddQuestStepChat(Quest, 2, "I need to check 'The Qeynos Exchange'.", 5, "I need to check the bank for someone who may have taken the pie", 0, 895.18, -18.01, -480.29, 238)
  29. AddQuestStepCompleteAction(Quest, 2, "step2beentobank")
  30. end
  31. function step1beentothesmithy(Quest, QuestGiver, Player)
  32. UpdateQuestStepDescription(Quest, 2, "I checked 'The Qeynos Exchange'")
  33. UpdateQuestTaskGroupDescription(Quest, 2, "I checked the bank, but found no one who took the pie")
  34. AddQuestStepChat(Quest, 3, "I need to investigate 'The Deepmug Tavern'.", 5, "I need to check the tavern for someone who may have taken the pie", 0, 880.47, -18.31, -443.50, 238)
  35. AddQuestStepCompleteAction(Quest, 3, "step3deepmug")
  36. end
  37. function step1beentothesmithy(Quest, QuestGiver, Player)
  38. UpdateQuestStepDescription(Quest, 3, "I smell the pie in 'The Deepmug Tavern'")
  39. UpdateQuestTaskGroupDescription(Quest, 3, "I smell the pie coming from someone in The Deepmug Tavern")
  40. AddQuestStepChat(Quest, 4, "I need to investigate 'The Deepmug Tavern'.", 5, "I need to check the tavern for someone who may have taken the pie", 0, 880.47, -18.31, -443.50, 238)
  41. AddQuestStepCompleteAction(Quest, 4, "step3deepmug")
  42. end
  43. function step1beentothesmithy(Quest, QuestGiver, Player)
  44. UpdateQuestStepDescription(Quest, 4, "I smell the pie in 'The Deepmug Tavern'")
  45. UpdateQuestTaskGroupDescription(Quest, 4, "I smell the pie coming from someone in The Deepmug Tavern")
  46. AddQuestStepChat(Quest, 5, "I need to investigate 'The Deepmug Tavern'.", 1, "I need to check the tavern for someone who may have taken the pie", 0, 2380030)
  47. AddQuestStepCompleteAction(Quest, 5, "ThiefFound")
  48. end
  49. function QuestComplete(Quest, QuestGiver, Player)
  50. UpdateQuestStepDescription(Quest, 5, "I've told Nyla about her lost pie.")
  51. UpdateQuestTaskGroupDescription(Quest, 5, "I've uncovered Nyla's pie thief and told Nyla who did it.")
  52. UpdateQuestStepDescription(Quest, "I told Nyla about her lost pie. I guess the thief was Lozoria over in the Deepmug tavern. Couldn't resist he said! Oh well, it seems like everything's all right though. ")
  53. GiveQuestReward(Quest, Player)
  54. end
  55. function Reload(Quest, QuestGiver, Player, Step)
  56. if Step == 1 then
  57. Step1Complete(Quest, QuestGiver, Player)
  58. elseif Step == 2 then
  59. QuestComplete(Quest, QuestGiver, Player)
  60. elseif Step == 3 then
  61. QuestComplete(Quest, QuestGiver, Player)
  62. elseif Step == 4 then
  63. QuestComplete(Quest, QuestGiver, Player)
  64. elseif Step == 5 then
  65. QuestComplete(Quest, QuestGiver, Player)
  66. end
  67. end