kill_or_be_killed.lua 2.5 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061
  1. --[[
  2. Script Name : Quests/ScaleYard/kill_or_be_killed.lua
  3. Script Purpose : Quest 343, Kill or be killed.
  4. Script Author : Xanibunib
  5. Script Date : 3.30.2009 (updated by torsten 1.8.2022)
  6. Zone : Scale Yard
  7. Quest Giver: Brood Matron Vrim Malthyk
  8. Quest ID# : 343
  9. Preceded by: Paying Homeage To The Past
  10. Followed by: Report To Enforcer Kurdak
  11. --]]
  12. function Init(Quest)
  13. AddQuestStepKill(Quest, 1, "Anthony Glavias must be relived of his duty as a member of the Freeport Militia.", 1, 100, "Militia member, Anthony Glvias, has proven to be too incompetant to serve in the Freeport Militia. He must be relived of his duty. He is currently stationed West of the Fountain of the Fallen Soldier.", 0, 1390038)
  14. AddQuestStepCompleteAction(Quest, 1, "Step1Complete")
  15. end
  16. function Step1Complete(Quest, QuestGiver, Player)
  17. UpdateQuestStepDescription(Quest, 1, "I talked to Anthony Glavias.")
  18. UpdateQuestTaskGroupDescription(Quest, 1, "I talked to Anthony Glavias but he attacked me.")
  19. local zone = GetZone(Player)
  20. local RuzbNPC = GetSpawnByLocationID(zone, 410590, false)
  21. Despawn(RuzbNPC)
  22. local Ruzb = GetSpawnByLocationID(zone, 133774148, false)
  23. local SpawnRuzb = SpawnByLocationID(zone, 133774148,false)
  24. Attack(SpawnRuzb, Player)
  25. AddQuestStepKill(Quest, 2, "Anthony Glavias must be relived of his duty as a member of the Freeport Militia.", 1, 100, "Militia member, Anthony Glvias, has proven to be too incompetant to serve in the Freeport Militia. He must be relived of his duty. He is currently stationed West of the Fountain of the Fallen Soldier.", 0, 1390125)
  26. AddQuestStepCompleteAction(Quest, 2, "AnthonyDead")
  27. end
  28. function AnthonyDead(Quest, QuestGiver, Player)
  29. UpdateQuestTaskGroupDescription(Quest, 2, "I have relived Anthony of his duty..")
  30. AddQuestStepChat(Quest, 3, "I must inform Vrim of my actions.", 1, "I must speak with Vrim.", 0, 1260003)
  31. AddQuestStepCompleteAction(Quest, 3, "QuestComplete")
  32. end
  33. function QuestComplete(Quest, QuestGiver, Player)
  34. UpdateQuestTaskGroupDescription(Quest, 2, "Anthony Glavias has been retired.")
  35. GiveQuestReward(Quest, Player)
  36. end
  37. function Accepted(Quest, QuestGiver, Player)
  38. end
  39. function Declined(Quest, QuestGiver, Player)
  40. end
  41. function Reload(Quest, QuestGiver, Player, Step)
  42. if Step == 1 then
  43. Step1Complete(Quest, QuestGiver, Player)
  44. elseif Step == 2 then
  45. AnthonyDead(Quest, QuestGiver, Player)
  46. elseif Step == 3 then
  47. QuestComplete(Quest, QuestGiver, Player)
  48. end
  49. end