AndreaDovesong.lua 8.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172
  1. --[[
  2. Script Name : SpawnScripts/NorthQeynos/AndreaDovesong.lua
  3. Script Author : Dorbin
  4. Script Date : 2022.04.25 03:04:17
  5. Script Purpose :
  6. :
  7. --]]
  8. dofile("SpawnScripts/Generic/GenericEcologyVoiceOvers.lua")
  9. local claymore = 5547
  10. local papers = 5536
  11. local duvo = 5524
  12. function spawn(NPC)
  13. SetPlayerProximityFunction(NPC, 6, "InRange", "LeaveRange")
  14. ProvidesQuest(NPC, claymore)
  15. ProvidesQuest(NPC, papers)
  16. end
  17. function respawn(NPC)
  18. spawn(NPC)
  19. end
  20. function InRange(NPC,Spawn)
  21. if GetFactionAmount(Spawn,11) <0 then
  22. FactionCheckingCallout(NPC, Spawn, faction)
  23. else
  24. if math.random(1, 100) <= 70 then
  25. FaceTarget(NPC,Spawn)
  26. choice = math.random(1,2)
  27. if choice == 1 then
  28. PlayFlavor(NPC, "", "", "curstey", 0, 0, Spawn)
  29. elseif choice == 2 then
  30. PlayFlavor(NPC, "", "", "royalwave", 0, 0, Spawn)
  31. end
  32. end
  33. end
  34. end
  35. function hailed(NPC, Spawn)
  36. if GetFactionAmount(Spawn,11) <0 then
  37. FaceTarget(NPC, Spawn)
  38. FactionChecking(NPC, Spawn, faction)
  39. else
  40. FaceTarget(Spawn, NPC)
  41. local conversation = CreateConversation()
  42. PlayFlavor(NPC, "voiceover/english/andrea_dovesong/qey_north/andreadovesong000.mp3", "", "hello", 2876603945, 556916518, Spawn)
  43. local conversation = CreateConversation()
  44. if not HasQuest(Spawn,claymore) and not HasCompletedQuest(Spawn, claymore) and HasQuest(Spawn,papers) or HasCompletedQuest(Spawn, papers) and not HasQuest(Spawn,claymore)and not HasCompletedQuest(Spawn, claymore) then
  45. AddConversationOption(conversation, "You were saying there are more statues like this one?", "Claymore2")
  46. end
  47. if GetQuestStep(Spawn,papers)==2 then
  48. AddConversationOption(conversation, "Here is the parchment you requested from Duvo. He said he has plenty more if you need.", "Delivered")
  49. end
  50. if not HasQuest(Spawn,claymore) and not HasCompletedQuest(Spawn, claymore) and not HasQuest(Spawn,papers) and not HasCompletedQuest(Spawn, papers)then
  51. AddConversationOption(conversation, "What kind of songs do you sing?", "Work")
  52. end
  53. if HasQuest(Spawn,claymore) or HasCompletedQuest(Spawn, claymore) then
  54. AddConversationOption(conversation, "Tell me again what you like to sing about.", "Work")
  55. end
  56. if not HasQuest(Spawn,papers) and not HasCompletedQuest(Spawn, papers) and HasQuest(Spawn, claymore) or not HasQuest(Spawn,papers) and not HasCompletedQuest(Spawn, papers) and HasCompletedQuest(Spawn, claymore)then
  57. AddConversationOption(conversation, "You seem quite busy here. Can I help you with anything while you perform?", "Work2")
  58. end
  59. AddConversationOption(conversation, "It is indeed!","kiss")
  60. AddConversationOption(conversation, "If you say so.")
  61. StartConversation(conversation, NPC, Spawn, "'Tis a lovely day for a tune, isn't it?")
  62. end
  63. end
  64. function kiss(NPC,Spawn)
  65. FaceTarget(NPC,Spawn)
  66. PlayFlavor(NPC, "", "", "kiss", 0, 0, Spawn)
  67. end
  68. function Work(NPC,Spawn)
  69. FaceTarget(NPC, Spawn)
  70. PlayFlavor(NPC, "voiceover/english/andrea_dovesong/qey_north/andreadovesong001.mp3", "", "orate", 3368204937, 3549759451, Spawn)
  71. local conversation = CreateConversation()
  72. AddConversationOption(conversation, "The claymore must be quite powerful to do with such a storied history.", "Claymore1")
  73. AddConversationOption(conversation, "Fascinating. Thanks for sharing.","agree")
  74. StartConversation(conversation, NPC, Spawn, "I sing songs about many things, but my favorite songs are about this monument right here. The mighty Qeynos Claymore! I sing songs about ancient Valius Bayle who first brought the sword to our world from its planar home. I sing songs of Antonius Bayle winning the sword in tournaments between the early human clans and how we used it to unite the human people within one kingdom! Aye, the Qeynos Claymore has a long and storied history.")
  75. end
  76. function Claymore1(NPC,Spawn)
  77. FaceTarget(NPC, Spawn)
  78. PlayFlavor(NPC, "voiceover/english/andrea_dovesong/qey_north/andreadovesong002.mp3", "", "agree", 2179201684, 4109286437, Spawn)
  79. local conversation = CreateConversation()
  80. if not HasQuest(Spawn,claymore) and not HasCompletedQuest(Spawn, claymore) then
  81. AddConversationOption(conversation, "There are monuments like this one somewhere else?", "Claymore2")
  82. end
  83. if HasQuest(Spawn,claymore) or HasCompletedQuest(Spawn, claymore) then
  84. AddConversationOption(conversation, "Wait, I've forgotten. You said there are more monuments like this one?", "Claymore2")
  85. end
  86. AddConversationOption(conversation, "Well, thankfully we can enjoy reflecting unpon our city's history with places like this.","agree")
  87. StartConversation(conversation, NPC, Spawn, "Aye, it is! Now, Antonia Bayle is the owner of the fine blade. And fortunately it is hidden away in the castle for its protection. Many agents of evil would like nothing better than to lay a hand upon it. For now, though, we only have these monuments to remind us of the claymore.")
  88. end
  89. function agree(NPC,Spawn)
  90. FaceTarget(NPC,Spawn)
  91. PlayFlavor(NPC, "", "", "agree", 0, 0, Spawn)
  92. end
  93. function Claymore2(NPC,Spawn)
  94. FaceTarget(NPC, Spawn)
  95. PlayFlavor(NPC, "voiceover/english/andrea_dovesong/qey_north/andreadovesong003.mp3", "", "nod", 4096047886, 1484152928, Spawn)
  96. local conversation = CreateConversation()
  97. if not HasQuest(Spawn,claymore) and not HasCompletedQuest(Spawn, claymore) then
  98. AddConversationOption(conversation, "I think I will. Thank you for sharing the story.", "Claymore3")
  99. end
  100. if HasCompletedQuest(Spawn, claymore) then
  101. AddConversationOption(conversation, "I've been to the one in Antonica since we last spoke. It is quite the sight overlooking the hills and coast.", "agree")
  102. end
  103. if not HasQuest(Spawn,papers) and not HasCompletedQuest(Spawn, papers) then
  104. AddConversationOption(conversation, "You seem quite busy here. Can I help you with anything while you perform?", "Work2")
  105. end
  106. AddConversationOption(conversation, "Well, thankfully we can enjoy reflecting unpon our city's history with places like this.","agree")
  107. StartConversation(conversation, NPC, Spawn, "Aye, there are others. In fact, another monument stands out in the Antonican hills. A small contingent of guards look over this Claymore Monument, and people often visit there to pray and meditate. Good travels to you if you plan on venturing out to see it.")
  108. end
  109. function Claymore3(NPC, Spawn)
  110. FaceTarget(NPC, Spawn)
  111. if not HasQuest(Spawn,claymore) and not HasCompletedQuest(Spawn, claymore) then
  112. OfferQuest(NPC, Spawn,claymore)
  113. end
  114. end
  115. function Work2(NPC, Spawn)
  116. FaceTarget(NPC, Spawn)
  117. PlayFlavor(NPC, "voiceover/english/andrea_dovesong/qey_north/andreadovesong004.mp3", "", "ponder", 2245604238, 844371971, Spawn)
  118. local conversation = CreateConversation()
  119. if HasQuest(Spawn,duvo) or HasCompletedQuest(Spawn, duvo) then
  120. AddConversationOption(conversation, "I've actually had dealings with Duvo. I'll stop by and see him.", "StartPapers")
  121. end
  122. AddConversationOption(conversation, "Gladly. I'll be back with the parchment", "StartPapers")
  123. AddConversationOption(conversation, "Parchment? Afraid I don't have the time.", "shrug")
  124. StartConversation(conversation, NPC, Spawn, "Looking for work are you? I could use some parchment to transcribe my sonnta. Scribe Duvo always has pleanty. You'll find him at the Elddar Grove. Bring me the parchment and I'll pay you for your troubles.")
  125. end
  126. function shrug(NPC,Spawn)
  127. FaceTarget(NPC,Spawn)
  128. PlayFlavor(NPC, "", "", "shrug", 0, 0, Spawn)
  129. end
  130. function StartPapers(NPC, Spawn)
  131. FaceTarget(NPC, Spawn)
  132. OfferQuest(NPC, Spawn,papers)
  133. end
  134. function Delivered(NPC, Spawn)
  135. FaceTarget(NPC, Spawn)
  136. PlayFlavor(NPC, "voiceover/english/andrea_dovesong/qey_north/andreadovesong005.mp3", "", "thanks", 3610265582, 997287857, Spawn)
  137. local conversation = CreateConversation()
  138. AddConversationOption(conversation, "Thank you.", "FinishPapers")
  139. StartConversation(conversation, NPC, Spawn, "How sweet and swift you are! Take these coins as a token of my appreciation.")
  140. end
  141. function FinishPapers(NPC,Spawn)
  142. PlayFlavor(NPC, "", "", "curtsey", 0, 0, Spawn)
  143. FaceTarget(NPC, Spawn)
  144. SetStepComplete(Spawn,papers, 2)
  145. end