9
3

spirits_of_the_night.lua 2.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748
  1. --[[
  2. Script Name : Quests/SunkenCity/spirits_of_the_night.lua
  3. Script Purpose : Handles the quest, "Spirits of the Night"
  4. Script Author : Scatman
  5. Script Date : 2009.07.28 (15.7.2022 by torsten)
  6. Zone : Sunken City
  7. Quest Giver: Inquisitor Thorson
  8. Preceded by: A Flowing Conversation (a_flowing_conversation.lua)
  9. Followed by: Cataloging Local Critters (cataloging_local_critters.lua)
  10. --]]
  11. function Init(Quest)
  12. AddQuestStepKill(Quest, 1, "I should defeat four undead creatures to obtain their spectral essences.", 4, 100, "I must search the Sunken City by night and collect the spectral essences of the undead that haunt this place.", 1240004, 1240005, 1240006, 1240029, 1240030, 1240031, 1240035, 1240036, 1240038, 1240039, 1240040, 1240041, 1240042, 1240043, 1240044)
  13. AddQuestStepCompleteAction(Quest, 1, "Step1_Complete_KilledSkeletons")
  14. end
  15. function Accepted(Quest, QuestGiver, Player)
  16. FaceTarget(QuestGiver, Player)
  17. conversation = CreateConversation()
  18. AddConversationOption(conversation, "I will return.")
  19. StartConversation(conversation, QuestGiver, Player, "The undead walk just ahead, though some lurk a bit farther in. Remember, more of these ghastly creatures can be found after night falls. Return to me when you have their essences.")
  20. end
  21. function Declined(Quest, QuestGiver, Player)
  22. end
  23. function Step1_Complete_KilledSkeletons(Quest, QuestGiver, Player)
  24. UpdateQuestStepDescription(Quest, 1, "I have obtained four spectral essences from the undead.")
  25. UpdateQuestTaskGroupDescription(Quest, 1, "I have defeated undead creatures and collected their spectral essences.")
  26. AddQuestStepChat(Quest, 2, "I should take the spectral essences to Inquisitor Thorson.", 1, "I need to return to Inquisitor Thorson and give him the essences.", 0, 1240024)
  27. AddQuestStepCompleteAction(Quest, 2, "Quest_Complete")
  28. end
  29. function Quest_Complete(Quest, QuestGiver, Player)
  30. UpdateQuestStepDescription(Quest, 2, "I have returned to Inquisitor Thorson.")
  31. UpdateQuestTaskGroupDescription(Quest, 2, "I told Thorson that I spoke to the strange iksar named Yarr.")
  32. GiveQuestReward(Quest, Player)
  33. UpdateQuestDescription(Quest, "I have obtained the essences of four undead beings in the Sunken City. It is my hope that studying these essences can help Investigator Thorson uncover the mysteries of this haunted place.")
  34. end
  35. function Reload(Quest, QuestGiver, Player, Step)
  36. if Step == 1 then
  37. Step1_Complete_KilledSkeletons(Quest, QuestGiver, Player)
  38. end
  39. end