attack_on_the_orc_leader.lua 3.3 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071
  1. --[[
  2. Script Name : Quests/IsleofRefuge/attack_on_the_orc_leader.lua
  3. Script Author : Dorbin
  4. Script Date : 2022.09.24 04:09:18
  5. Script Purpose :
  6. Zone : IsleofRefuge
  7. Quest Giver: Mizan
  8. Preceded by: Striking Back at the Golbins
  9. Followed by: None
  10. --]]
  11. require "SpawnScripts/Generic/DialogModule"
  12. function Init(Quest)
  13. AddQuestStepZoneLoc(Quest, 1, "I need to enter the orc cave.", 1, "I must find my way through the goblin camps and enter the orc leader's cave on the northeastern part of the island.", 11,-13.77, 0.00, -3.00, 324)
  14. AddQuestStepCompleteAction(Quest, 1, "Step1Complete")
  15. end
  16. function Accepted(Quest, QuestGiver, Player)
  17. FaceTarget(QuestGiver, Player)
  18. Dialog.New(QuestGiver, Player)
  19. Dialog.AddDialog("Fantastic! Your magical skills are vital in successfully attacking this evil orc. Wield your magic arts and destroy the creature that commands the attacks against our settlement! The orc resides in a cave on the northeast side of the island. Find the cave and slay the beast.")
  20. Dialog.AddVoiceover("voiceover/english/mizan_vaeoulin/tutorial_island02/mizanvaeoulin013.mp3", 703001455, 1456004072)
  21. PlayFlavor(QuestGiver, "", "", "smile", 0, 0, Player)
  22. Dialog.AddOption("I'll return once the deed is done.")
  23. Dialog.Start()
  24. end
  25. function Declined(Quest, QuestGiver, Player)
  26. -- Add dialog here for when the quest is declined
  27. end
  28. function Deleted(Quest, QuestGiver, Player)
  29. -- Remove any quest specific items here when the quest is deleted
  30. end
  31. function Step1Complete(Quest, QuestGiver, Player)
  32. UpdateQuestStepDescription(Quest, 1, "I entered the orc's cave.")
  33. UpdateQuestTaskGroupDescription(Quest, 1, "I entered the orc's cave.")
  34. AddQuestStepKill(Quest, 2, "I need to slay the orc leader.", 1, 100, "I need to slay Grimgash the Black, the orc that is behind the goblin attacks.", 11, 3240000)
  35. AddQuestStepCompleteAction(Quest, 2, "Step2Complete")
  36. end
  37. function Step2Complete(Quest, QuestGiver, Player)
  38. UpdateQuestStepDescription(Quest, 2, "I defeated the orc leader.")
  39. UpdateQuestTaskGroupDescription(Quest, 2, "I help slay the self appointed king of the orcs.")
  40. AddQuestStepChat(Quest, 3, "I should speak to Mizan.", 1, "I need to return to Mizan to let him know the orc has been removed from power.", 11, 3250057)
  41. AddQuestStepCompleteAction(Quest, 3, "QuestComplete")
  42. end
  43. function QuestComplete(Quest, QuestGiver, Player)
  44. -- The following UpdateQuestStepDescription and UpdateTaskGroupDescription are not needed, parser adds them for completion in case stuff needs to be moved around
  45. UpdateQuestStepDescription(Quest, 3, "I spoke with Mizan.")
  46. UpdateQuestTaskGroupDescription(Quest, 3, "I spoke with Mizan.")
  47. UpdateQuestDescription(Quest, "The orc leader is now dead. Hopefully with his death the goblin attacks will stop and the goblins will retreat back from the outposts walls. Mizan presented me with a staff for all the work I have done for him and the Far Seas settlement.")
  48. GiveQuestReward(Quest, Player)
  49. end
  50. function Reload(Quest, QuestGiver, Player, Step)
  51. if Step == 1 then
  52. Step1Complete(Quest, QuestGiver, Player)
  53. elseif Step == 2 then
  54. Step2Complete(Quest, QuestGiver, Player)
  55. elseif Step == 3 then
  56. QuestComplete(Quest, QuestGiver, Player)
  57. end
  58. end