9
3

bartering_crystals.lua 1.8 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849
  1. --[[
  2. Script Name : Quests/FrostfangSea/bartering_crstals.lua
  3. Script Purpose : for the quest "Bartering Crystals"
  4. Script Author : theFoof
  5. Script Date : 2013.5.30
  6. Script Notes :
  7. Zone : Frostfang Sea
  8. Quest Giver : Flibbit Quagmarr
  9. Preceded by : The Absent Effigy
  10. Followed by : Pelted
  11. --]]
  12. function Init(Quest)
  13. AddQuestStep(Quest, 1, "I must collect strange ice crystals from upon the Icemane Plains.", 5, 100, "I should head out to the Icemane Plains and collect any strange ice crystals I may find.", 2938)
  14. AddQuestStepCompleteAction(Quest, 1, "GotCrystals")
  15. AddQuestRewardCoin(Quest, math.random(9,80), math.random(13,25), 0, 0)
  16. end
  17. function Accepted(Quest, QuestGiver, Player)
  18. FaceTarget(QuestGiver, Player)
  19. conversation = CreateConversation()
  20. PlayFlavor(QuestGiver, "flibbit_quagmarr/halas/gwenevyns_cove/flibbit_quagmarr/flibbit_quagmarr_044.mp3", "", "", 86681713, 2082517769, Player)
  21. AddConversationOption(conversation, "I shall return with the crystals.")
  22. StartConversation(conversation, QuestGiver, Player, "Thank you, " .. GetName(Player) .. ".")
  23. end
  24. function Deleted(Quest, QuestGiver, Player)
  25. end
  26. function Declined(Quest, QuestGiver, Player)
  27. end
  28. function GotCrystals(Quest, QuestGiver, Player)
  29. UpdateQuestTaskGroupDescription(Quest, 1, "I have collected the strange ice crystals.")
  30. AddQuestStepChat(Quest, 2, "I must speak with Flibbit Quagmarr. Flibbit is staying in Gwenevyn's Cove.", 1, "I must speak with Flibbit Quagmarr. Flibbit is staying in Gwenevyn's Cove.", 0, 4700045)
  31. AddQuestStepCompleteAction(Quest, 2, "CompleteQuest")
  32. end
  33. function CompleteQuest(Quest, QuestGiver, Player)
  34. GiveQuestReward(Quest, Player)
  35. end
  36. function Reload(Quest, QuestGiver, Player, Step)
  37. if Step == 1 then
  38. GotCrystals(Quest, QuestGiver, Player)
  39. end
  40. end