9
3

ham_and_beans.lua 2.7 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364
  1. --[[
  2. Script Name : Quests/FrostfangSea/ham_and_beans.lua
  3. Script Purpose : the quest Ham and Beans
  4. Script Author : theFoof
  5. Script Date : 2013.9.2
  6. Script Notes :
  7. Zone : Frostfang Sea
  8. Quest Giver : Barker Gordon
  9. Preceded by : None
  10. Followed by : None
  11. --]]
  12. function Init(Quest)
  13. AddQuestStep(Quest, 1, "I must collect halasian beans for Barker's meal.", 1, 100, "I must collect halasian beans for Barker. I can find the halasian beans at the shaman hut called Pilgrims' Hearth in southwest New Halas.", 805)
  14. AddQuestStepCompleteAction(Quest, 1, "GotBeans")
  15. end
  16. function Accepted(Quest, QuestGiver, Player)
  17. FaceTarget(QuestGiver, Player)
  18. conversation = CreateConversation()
  19. PlayFlavor(QuestGiver, "barker_gordon/halas/new_halas/barker_gordon/barker_gordon_008.mp3", "", "", 3672106737, 3369025535, Player)
  20. AddConversationOption(conversation, "Okay then, I will return with the ham and beans.")
  21. StartConversation(conversation, QuestGiver, Player, "Since you'll be up that way, could you also pick me up some halasian beans? They're at the shaman hut called Pilgrims' Hearth in southwest New Halas.")
  22. end
  23. function Deleted(Quest, QuestGiver, Player)
  24. end
  25. function Declined(Quest, QuestGiver, Player)
  26. end
  27. function GotBeans(Quest, QuestGiver, Player)
  28. UpdateQuestTaskGroupDescription(Quest, 1, "I have collected the halasian beans for Barker.")
  29. AddQuestStepKill(Quest, 2, "I must kill Bentor the Mighty for Barker's meal.", 1, 100, "I must kill Bentor the Mighty for Barker. Bentor the Mighty is in the pen next to the mender's workshop, The Stone Hammer, in New Halas.", 611, 4700251)
  30. AddQuestStepCompleteAction(Quest, 2, "KilledPig")
  31. end
  32. function KilledPig(Quest, QuestGiver, Player)
  33. UpdateQuestTaskGroupDescription(Quest, 2, "I have killed and collected Bentor the Mighty's meat for Barker.")
  34. AddQuestStepChat(Quest, 3, "I must speak with Barker Gordon at the Erollis Dock.", 1, "I must return the halasian beans and meat from Bentor to Barker Gordon. Barker is at the Erollis Dock in New Halas.", 0, 4700242)
  35. AddQuestStepCompleteAction(Quest, 3, "TalkedBarker")
  36. end
  37. function TalkedBarker(Quest, QuestGiver, Player)
  38. UpdateQuestTaskGroupDescription(Quest, 3, "I have given the ingredients to Barker.")
  39. AddQuestStep(Quest, 4, "I must try some of Barker's ham and beans.", 1, 100, "Barker has taken the ingredients I collected and prepared his recipe for ham and beans.", 297)
  40. AddQuestStepCompleteAction(Quest, 4, "CompleteQuest")
  41. end
  42. function CompleteQuest(Quest, QuestGiver, Player)
  43. GiveQuestReward(Quest, Player)
  44. end
  45. function Reload(Quest, QuestGiver, Player, Step)
  46. if Step == 1 then
  47. GotBeans(Quest, QuestGiver, Player)
  48. elseif Step == 2 then
  49. KilledPig(Quest, QuestGiver, Player)
  50. elseif Step == 3 then
  51. TalkedBarker(Quest, QuestGiver, Player)
  52. end
  53. end