9
3

the_missing_book.lua 2.6 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061
  1. --[[
  2. Script Name : the_missing_book.lua
  3. Script Purpose : Handles the quest, "The Missing Book"
  4. Script Author : torsten
  5. Script Date : 19.07.2022
  6. Script Notes :
  7. Zone : Longshadow Alley
  8. Quest Giver : Lotni K`Iria
  9. Preceded by : None
  10. Followed by : Magical Retribution
  11. --]]
  12. require "SpawnScripts/Generic/DialogModule"
  13. function Init(Quest)
  14. AddQuestStep(Quest, 1, "I need to find the thief.", 1,100, "I need to find and speak to the Ratonga who stole Lotni's book.", 11)
  15. AddQuestStepCompleteAction(Quest, 1, "Step1Complete")
  16. UpdateQuestZone(Quest,"Temple Street")
  17. end
  18. function Step1Complete(Quest, QuestGiver, Player)
  19. UpdateQuestStepDescription(Quest, 1, "I spoke to the Ratonga thief, Chrna.")
  20. UpdateQuestTaskGroupDescription(Quest, 1, "I found the Ratonga, but she didn't have the book.")
  21. UpdateQuestZone(Quest,"Longshadow Ally")
  22. AddQuestStepChat(Quest, 2, "I should return to Lotni.", 1, "I should tell Lotni K'Lria that Chrna doesn't have the book anymore.", 11, 1380009)
  23. AddQuestStepCompleteAction(Quest, 2, "QuestComplete")
  24. end
  25. function QuestComplete(Quest, QuestGiver, Player)
  26. UpdateQuestDescription(Quest, "Lotni claims she already spoke to the mastermind behind the theft. Unfortunately,she already killed him when his answers were not satisfactory. I doubt she will ever get her book back.")
  27. UpdateQuestStepDescription(Quest, 2, "I have told Lotni about the fate of her book.")
  28. UpdateQuestTaskGroupDescription(Quest, 2, "I have told Lotni about the fate of her book.")
  29. GiveQuestReward(Quest, Player)
  30. end
  31. function Accepted(Quest, QuestGiver, Player)
  32. FaceTarget(QuestGiver, Player)
  33. Dialog.New(QuestGiver, Player)
  34. Dialog.AddDialog("You'd help me? Well, if you're offering ... The last time I saw the book, a ratonga was leaving my room. When I confronted her, she claimed she was lost. I'm certain she took the book. Why don't you check Temple Street and track her down? Do whatever you need to get that book from her!")
  35. PlayFlavor(QuestGiver,"","","boggle",0,0,Player)
  36. Dialog.AddVoiceover("voiceover/english/standard_dark_elf_female/fprt_hood05/quests/lotniklria/lotni_x1_accept.mp3", 1332546096, 2822860601)
  37. Dialog.AddOption("I'll see it done.")
  38. Dialog.Start()
  39. end
  40. function Declined(Quest, QuestGiver, Player)
  41. -- Add dialog here for when the quest is declined
  42. end
  43. function Deleted(Quest, QuestGiver, Player)
  44. -- Remove any quest specific items here when the quest is deleted
  45. end
  46. function Reload(Quest, QuestGiver, Player, Step)
  47. if Step == 1 then
  48. Step1Complete(Quest, QuestGiver, Player)
  49. elseif Step == 2 then
  50. QuestComplete(Quest, QuestGiver, Player)
  51. end
  52. end