SpiritofRaegnir.lua 5.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112
  1. --[[
  2. Script Name : SpawnScripts/Commonlands/SpiritofRaegnir.lua
  3. Script Author : Premierio015
  4. Script Date : 2021.02.27 09:02:32
  5. Script Purpose :
  6. :
  7. --]]
  8. local AnOrcishTrinket = 5254
  9. function spawn(NPC)
  10. end
  11. function hailed(NPC, Spawn)
  12. FaceTarget(NPC, Spawn)
  13. if not HasQuest(Spawn, AnOrcishTrinket) then
  14. local choice = math.random(1, 3)
  15. if choice == 1 then
  16. PlayFlavor(NPC, "", "My pain is eternal.", "", 0, 0, Spawn)
  17. elseif choice == 2 then
  18. PlayFlavor(NPC, "", "Rest comes not.", "", 0, 0, Spawn)
  19. else
  20. PlayFlavor(NPC, "", "It is missing.", "", 0, 0, Spawn)
  21. end
  22. elseif GetQuestStep(Spawn, AnOrcishTrinket) == 5 then
  23. local conversation = CreateConversation()
  24. AddConversationOption(conversation, "I come with a gift. [show him the blade and jewels]", "Option1")
  25. StartConversation(conversation, NPC, Spawn, "Why do you bother me?")
  26. end
  27. end
  28. function Option1(NPC, Spawn)
  29. FaceTarget(NPC, Spawn)
  30. local conversation = CreateConversation()
  31. AddConversationOption(conversation, "Is that why your spirit still lingers? You wanted your blade?", "Option2")
  32. StartConversation(conversation, NPC, Spawn, "My blade! I thought I had lost it in that blasted city.")
  33. end
  34. function Option2(NPC, Spawn)
  35. FaceTarget(NPC, Spawn)
  36. local conversation = CreateConversation()
  37. AddConversationOption(conversation, "How?", "Option3")
  38. StartConversation(conversation, NPC, Spawn, "No. I am unable to rest because I was betrayed.")
  39. end
  40. function Option3(NPC, Spawn)
  41. FaceTarget(NPC, Spawn)
  42. local conversation = CreateConversation()
  43. AddConversationOption(conversation, "...", "Option4")
  44. StartConversation(conversation, NPC, Spawn, "By my own people! I got the crazy idea in my head that we could sneak into Freeport at night and take out a guard captain. The captain's head would be merely a worthless trophy, we had dozens already. But the fact that we stole it from his very shoulders while he slept... THAT was to be the real prize. But it all went wrong...")
  45. end
  46. function Option4(NPC, Spawn)
  47. FaceTarget(NPC, Spawn)
  48. local conversation = CreateConversation()
  49. AddConversationOption(conversation, "What trap?", "Option5")
  50. StartConversation(conversation, NPC, Spawn, "No one knew of our plan that wasn't of orc blood. Orcs aren't known for their smarts, but we don't talk. Some might, sure, if they were captured. But I specifically toned down our presence so as to avoid any capture. And we did avoid it. We had not a single orc unaccounted for in two weeks, completely unheard of. But the Militia had set a trap for us.")
  51. end
  52. function Option5(NPC, Spawn)
  53. FaceTarget(NPC, Spawn)
  54. local conversation = CreateConversation()
  55. AddConversationOption(conversation, "...", "Option6")
  56. StartConversation(conversation, NPC, Spawn, "We crept into the house of the guard captain. We had gone not three steps when there came a terrible crashing from all around us. The guard in his bed? Probably just some pillows under the covers. They had set the entire house up as a trap, and it worked. Every last one of us they got, crushed under that falling mess of stone...")
  57. end
  58. function Option6(NPC, Spawn)
  59. FaceTarget(NPC, Spawn)
  60. local conversation = CreateConversation()
  61. AddConversationOption(conversation, "That story is not how I heard it.", "Option7")
  62. StartConversation(conversation, NPC, Spawn, "Who knew? Not a single orc captured or missing. And ONLY us orcs knew. One of them told the Militia... I bet they gave him enough gold to keep him happy for a day or two and then killed him. Why not? He's just an orc, ya know? And a traitor at that. Betrayal hurts... more than any wound a sword or axe can give.")
  63. end
  64. function Option7(NPC, Spawn)
  65. FaceTarget(NPC, Spawn)
  66. local conversation = CreateConversation()
  67. AddConversationOption(conversation, "From what I heard, orcs stationed in the Commonlands thought that they could help you accomplish your mission if they fired their catapults into the city. It would seem they hit the house of the captain, killing him and your men.", "Option8")
  68. StartConversation(conversation, NPC, Spawn, "What do you mean?")
  69. end
  70. function Option8(NPC, Spawn)
  71. FaceTarget(NPC, Spawn)
  72. local conversation = CreateConversation()
  73. AddConversationOption(conversation, "Yes.", "Option9")
  74. StartConversation(conversation, NPC, Spawn, "... they hit the house of the guard captain?")
  75. end
  76. function Option9(NPC, Spawn)
  77. FaceTarget(NPC, Spawn)
  78. local conversation = CreateConversation()
  79. AddConversationOption(conversation, "Your orcs did not betray you.", "Option10")
  80. StartConversation(conversation, NPC, Spawn, "Hah hah hah. So we sneak into Freeport to kill some guard captain, get killed, and the poor guy dies anyway? Hah hah hah! Oh, the world works in interesting ways.")
  81. end
  82. function Option10(NPC, Spawn)
  83. SetStepComplete(Spawn, AnOrcishTrinket, 5)
  84. FaceTarget(NPC, Spawn)
  85. local conversation = CreateConversation()
  86. AddConversationOption(conversation, "You are welcome.")
  87. StartConversation(conversation, NPC, Spawn, "No. No they did not. You bring me my weapon and my peace. I think I will leave now. Thank you.")
  88. PlayAnimation(NPC, 121) -- "bow" animation
  89. end
  90. function respawn(NPC)
  91. end