BrandusLevine.lua 19 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302
  1. --[[
  2. Script Name : SpawnScripts/Commonlands/BrandusLevine.lua
  3. Script Author : Premierio015
  4. Script Date : 2020.11.13 07:11:27
  5. Script Purpose :
  6. :
  7. --]]
  8. local TheMysteriousMissingShipment = 421
  9. local StartingtheNegotiations = 424
  10. local FinishingtheNegotiations = 425
  11. function spawn(NPC)
  12. ProvidesQuest(NPC, TheMysteriousMissingShipment)
  13. ProvidesQuest(NPC, StartingtheNegotiations)
  14. ProvidesQuest(NPC, FinishingtheNegotiations)
  15. end
  16. function hailed(NPC, Spawn)
  17. FaceTarget(NPC, Spawn)
  18. conversation = CreateConversation()
  19. if not HasQuest(Spawn, TheMysteriousMissingShipment) and not HasCompletedQuest(Spawn, TheMysteriousMissingShipment) then
  20. PlayFlavor(NPC, "voiceover/english/voice_emotes/greetings/greetings_2_1034.mp3", "", "ponder", 0, 0, Spawn)
  21. AddConversationOption(conversation, "Another person who needs help? Fine, what do you need?", "dlg1")
  22. AddConversationOption(conversation, "I'll help you only if it pays well.", "dlg3")
  23. AddConversationOption(conversation, "I would be happy to help you.", "dlg2")
  24. AddConversationOption(conversation, "You have to be kidding me. No thanks, find another lackey, I'm busy with my own important things.")
  25. StartConversation(conversation, NPC, Spawn, "Hrmmm... You do have the look of a citizen about you. You're not just random rabble from the streets. I could use your help.")
  26. elseif HasQuest(Spawn, TheMysteriousMissingShipment) and GetQuestStep(Spawn, TheMysteriousMissingShipment) == 1 or GetQuestStep(Spawn, StartingtheNegotiations) <= 8 and HasQuest(Spawn, StartingtheNegotiations) or HasQuest(Spawn, FinishingtheNegotiations) and GetQuestStep(Spawn, FinishingtheNegotiations) == 1 or GetQuestStep(Spawn, FinishingtheNegotiations) == 3 or GetQuestStep(Spawn, FinishingtheNegotiations) == 4 then
  27. PlayFlavor(NPC, "voiceover/english/voice_emotes/greetings/greetings_3_1034.mp3", "", "no", 0, 0, Spawn)
  28. AddConversationOption(conversation, "I'll be back when I'm done.")
  29. StartConversation(conversation, NPC, Spawn, "Look, I don't have time to sit around and talk about the weather. We have an agreement and I expect you to live up to it. Now don't come back unless you're done with what I asked.")
  30. elseif HasQuest(Spawn, TheMysteriousMissingShipment) and GetQuestStep(Spawn, TheMysteriousMissingShipment) == 3 then
  31. PlayFlavor(NPC, "voiceover/english/voice_emotes/greetings/greetings_2_1034.mp3", "", "", 0, 0, Spawn)
  32. AddConversationOption(conversation, "Nethet had me running all over the place helping friends of his.", "dlg8")
  33. AddConversationOption(conversation, "Nethet had some information. The dervish cutthroats stole your shipment and apparently have your sorcerer.", "dlg9")
  34. AddConversationOption(conversation, "I don't have any new information yet.")
  35. StartConversation(conversation, NPC, Spawn, "What did Nethet tell you? That rat had better have known something or I'm back where I started. That will not make me a happy man.")
  36. elseif HasCompletedQuest(Spawn, TheMysteriousMissingShipment) and not HasQuest(Spawn, StartingtheNegotiations) and not HasCompletedQuest(Spawn, StartingtheNegotiations) then
  37. dlg9(NPC, Spawn)
  38. elseif GetQuestStep(Spawn, StartingtheNegotiations) == 9 then
  39. PlayFlavor(NPC, "brandus_levine/commonlands/quests/brandus_levine/brandus_levine020.mp3", "", "", 2488060767, 2522972725, Spawn)
  40. AddConversationOption(conversation, "You asked for a few dozen. That is what I delivered.", "dlg14")
  41. AddConversationOption(conversation, "Not enough, there were still some left.", "dlg14")
  42. AddConversationOption(conversation, "I just want to get this over with and get what is due to me.", "dlg14")
  43. StartConversation(conversation, NPC, Spawn, "That was faster than I expected, you're quite the dangerous one aren't you? Well done, I applaud you and your efforts in our partnership here. Keep it up and we might get very rich together. Tell me, how many did you get rid of before coming back?")
  44. elseif HasCompletedQuest(Spawn, TheMysteriousMissingShipment) and HasCompletedQuest(Spawn, StartingtheNegotiations) and not HasQuest(Spawn, FinishingtheNegotiations) and NotHasCompletedQuest(Spawn, FinishingtheNegotiations) then
  45. PlayFlavor(NPC, "voiceover/english/voice_emotes/greetings/greetings_2_1034.mp3", "", "", 0, 0, Spawn)
  46. AddConversationOption(conversation, "Yes, I'm ready to continue.", "dlg15")
  47. AddConversationOption(conversation, "Not right now, I'll return later.")
  48. StartConversation(conversation, NPC, Spawn, "Shall we continue our business venture, partner?")
  49. elseif GetQuestStep(Spawn, FinishingtheNegotiations) == 2 then
  50. dlg18(NPC, Spawn)
  51. elseif GetQuestStep(Spawn, FinishingtheNegotiations) == 6 then
  52. dlg22(NPC, Spawn)
  53. end
  54. end
  55. function dlg1(NPC, Spawn)
  56. FaceTarget(NPC, Spawn)
  57. conversation = CreateConversation()
  58. PlayFlavor(NPC, "brandus_levine/commonlands/quests/brandus_levine/brandus_levine002.mp3", "", "ponder", 262730364, 1884373532, Spawn)
  59. AddConversationOption(conversation, "Get to the point already.", "dlg5")
  60. AddConversationOption(conversation, "I'm assuming that's a threat, I'll pretend I didn't hear it. What did you have in mind?", "dlg5")
  61. AddConversationOption(conversation, "Obscurity is my middle name. How about I just obscure myself out of this conversation.")
  62. StartConversation(conversation, NPC, Spawn, "You do realize I can find someone else. And maybe you'll just fade into obscurity. But, since you've at least shown some interest then perhaps I can use you.")
  63. end
  64. function dlg2(NPC, Spawn)
  65. FaceTarget(NPC, Spawn)
  66. conversation = CreateConversation()
  67. PlayFlavor(NPC, "brandus_levine/commonlands/quests/brandus_levine/brandus_levine004.mp3", "", "", 305934204, 2024549973, Spawn)
  68. AddConversationOption(conversation, "So, what is it you needed such dire help on?", "dlg5")
  69. AddConversationOption(conversation, "Citizen? Do you even know who I am? I have no time for such arrogance.")
  70. StartConversation(conversation, NPC, Spawn, "Good, good, I like to see such eagerness in a citizen of Freeport.")
  71. end
  72. function dlg4(NPC, Spawn)
  73. FaceTarget(NPC, Spawn)
  74. conversation = CreateConversation()
  75. AddConversationOption(conversation, "And how would you expect me to find it if I have no idea what it is?", "dlg7")
  76. AddConversationOption(conversation, "On second thought, if you're not going to tell me what I need to know I think I'll just leave.")
  77. StartConversation(conversation, NPC, Spawn, "That little bit of information you don't need to know. All I'm asking for is that you find my missing cargo.")
  78. end
  79. function dlg3(NPC, Spawn)
  80. FaceTarget(NPC, Spawn)
  81. conversation = CreateConversation()
  82. PlayFlavor(NPC, "brandus_levine/commonlands/quests/brandus_levine/brandus_levine003.mp3", "", "", 324578518, 1128092434, Spawn)
  83. AddConversationOption(conversation, "Reward. I like the sound of that. What did you have in mind?", "dlg5")
  84. AddConversationOption(conversation, "You don't look like you could afford my standard fee. I think I'll go look for adventure elsewhere.")
  85. StartConversation(conversation, NPC, Spawn, "Oh, it pays well, very well indeed. I don't ask simple things but I reward loyal service.")
  86. end
  87. function dlg5(NPC, Spawn)
  88. FaceTarget(NPC, Spawn)
  89. conversation = CreateConversation()
  90. PlayFlavor(NPC, "brandus_levine/commonlands/quests/brandus_levine/brandus_levine005.mp3", "", "", 3809469840, 3688681939, Spawn)
  91. AddConversationOption(conversation, "What was in this shipment of yours that's so important?", "dlg4")
  92. AddConversationOption(conversation, "I think I can do that, where should I start looking?", "dlg7")
  93. AddConversationOption(conversation, "I thought this would be interesting. Forget it, this sounds like another waste of my precious time.")
  94. StartConversation(conversation, NPC, Spawn, "I've been waiting on a very special shipment to arrive. It was due here three days ago and there has been no sign of the individuals who were supposed to bring it. I've had to send the boat to the Freeport docks and every day it sits there it's costing me money. I need you to find out what happened to my shipment or why they are so late.")
  95. end
  96. function dlg7(NPC, Spawn)
  97. FaceTarget(NPC, Spawn)
  98. conversation = CreateConversation()
  99. PlayFlavor(NPC, "brandus_levine/commonlands/quests/brandus_levine/brandus_levine007.mp3", "", "", 3066832295, 2286961802, Spawn)
  100. AddConversationOption(conversation, "I'll start with him then.", "offer1")
  101. StartConversation(conversation, NPC, Spawn, "Fine, if I have to hold your hand through everything. You might start with Nethet near the main gates of Freeport. He watches most of who enter or leave the city. If anyone knows anything about where my missing cargo went it would likely be him.")
  102. end
  103. function dlg8(NPC, Spawn)
  104. FaceTarget(NPC, Spawn)
  105. conversation = CreateConversation()
  106. AddConversationOption(conversation, "Thanks for the sympathy. Yes, he had information that the dervish cutthroats stole your shipment and your sorcerer.", "dlg9")
  107. AddConversationOption(conversation, "With that tone of voice, find the shipment yourself, I'm through with this.")
  108. StartConversation(conversation, NPC, Spawn, "Don't tell me your whining stories about what other people had you do. He could have made you shovel pig dung for all I care, did you get the information or not?")
  109. end
  110. function dlg9(NPC, Spawn)
  111. FaceTarget(NPC, Spawn)
  112. if HasQuest(Spawn, TheMysteriousMissingShipment) and GetQuestStep(Spawn, TheMysteriousMissingShipment) == 3 then
  113. SetStepComplete(Spawn, TheMysteriousMissingShipment, 3)
  114. end
  115. conversation = CreateConversation()
  116. AddConversationOption(conversation, "My pleasure, you'll hear their screams from here.", "dlg10")
  117. AddConversationOption(conversation, "Now you want me to kill people for you? What's in it for me?", "dlg11")
  118. AddConversationOption(conversation, "I know you're selling refugees back to the Far Seas Trading Company.", "dlg12")
  119. AddConversationOption(conversation, "I'm not killing anyone, do it yourself I'm done with you.")
  120. StartConversation(conversation, NPC, Spawn, "The dervishes stole it!? You can't be serious. Argh!! I'm tired of those lowlifes messing with my business. I need you to do me a favor and kill a few dozen of them.")
  121. end
  122. function dlg10(NPC, Spawn)
  123. FaceTarget(NPC, Spawn)
  124. PlayFlavor(NPC, "brandus_levine/commonlands/quests/brandus_levine/brandus_levine015.mp3", "", "", 1439836789, 4202652757, Spawn)
  125. conversation = CreateConversation()
  126. AddConversationOption(conversation, "Alright. I'll be back when I'm done.", "offer2")
  127. AddConversationOption(conversation, "Not right now.")
  128. StartConversation(conversation, NPC, Spawn, "That's exactly what I wanted to hear. Once you've thinned out the number of the dervishes for me I have a feeling they might be willing to negotiate a deal afterwards. I want them to learn a lesson in fouling my business. You can find one of the larger encampments on the far Western end of the Commonlands.")
  129. end
  130. function dlg11(NPC, Spawn)
  131. FaceTarget(NPC, Spawn)
  132. conversation = CreateConversation()
  133. AddConversationOption(conversation, "When you put it that way how can I refuse?", "dlg10")
  134. AddConversationOption(conversation, "Forget it, I'm not interested.")
  135. StartConversation(conversation, NPC, Spawn, "Oh, you'll be rewarded for this I assure you. I want the dervishes to pay and I'm willing to let you in on some of my profits if you help me out with this.")
  136. end
  137. function dlg12(NPC, Spawn)
  138. FaceTarget(NPC, Spawn)
  139. PlayFlavor(NPC, "brandus_levine/commonlands/quests/brandus_levine/brandus_levine018.mp3", "", "", 4047037445, 2150242862, Spawn)
  140. conversation = CreateConversation()
  141. AddConversationOption(conversation, "How about a few extra coins in my pocket?", "dlg13")
  142. AddConversationOption(conversation, "Nothing, I just found it interesting and fairly clever. I want in on the profits though.")
  143. StartConversation(conversation, NPC, Spawn, "How did.... Nethet ... curse that rat, he finds out way more than he should. Alright, what do you want to keep quiet about it?")
  144. end
  145. function dlg13(NPC, Spawn)
  146. FaceTarget(NPC, Spawn)
  147. PlayFlavor(NPC, "brandus_levine/commonlands/quests/brandus_levine/brandus_levine019.mp3", "", "", 2588958758, 3569990697, Spawn)
  148. conversation = CreateConversation()
  149. AddConversationOption(conversation, "Thank you Brandus, I knew you'd see things my way.")
  150. AddConversationOption(conversation, "That's more like it. I'll be back soon.")
  151. StartConversation(conversation, NPC, Spawn, "I can do that if it'll keep you quiet. I don't have any coin on me here though, bad idea walking around with a lot of money on the docks you understand. Go to the Crossroads, I have a business partner named Anders Blackhammer who can give you the profits from our last venture. Tell him that I sent you.")
  152. end
  153. function dlg14(NPC, Spawn)
  154. FaceTarget(NPC, Spawn)
  155. SetStepComplete(Spawn, StartingtheNegotiations, 9)
  156. PlayFlavor(NPC, "brandus_levine/commonlands/quests/brandus_levine/brandus_levine021.mp3", "", "", 2051967454, 3084787135, Spawn)
  157. conversation = CreateConversation()
  158. AddConversationOption(conversation, "Thanks, I'll be back soon to continue our ''negotiations'' with the dervishes.")
  159. StartConversation(conversation, NPC, Spawn, "I understand what you mean perfectly. Here is the first of your profits, if you keep doing such excellent work there is a lot more where this came from.")
  160. end
  161. -- FINISHING THE NEGOTIATIONS PART
  162. function dlg15(NPC, Spawn)
  163. FaceTarget(NPC, Spawn)
  164. conversation = CreateConversation()
  165. AddConversationOption(conversation, "And you want me to find out which is the truth?", "dlg16")
  166. AddConversationOption(conversation, "I don't really have time for this right now.")
  167. StartConversation(conversation, NPC, Spawn, "Good. The dervishes are still not willing to negotiate. I'm guessing they have either become more foolish than normal or they no longer have my shipment.")
  168. end
  169. function dlg16(NPC, Spawn)
  170. FaceTarget(NPC, Spawn)
  171. conversation = CreateConversation()
  172. AddConversationOption(conversation, "So, I should go speak with this Captain Vertas?", "dlg17")
  173. AddConversationOption(conversation, "I thought this would be something interesting, forget it.")
  174. StartConversation(conversation, NPC, Spawn, "Yes, but I have another source that we might be able to use to our advantage. Another militia guard by the name of Captain Vertas is stationed out in the Crossroads. He has no love for the dervishes and keeps a close eye on them.")
  175. end
  176. function dlg17(NPC, Spawn)
  177. FaceTarget(NPC, Spawn)
  178. conversation = CreateConversation()
  179. AddConversationOption(conversation, "I'll be back when I learn anything.", "offer3")
  180. StartConversation(conversation, NPC, Spawn, "Yes, see what information he has on the dervishes and what we might be able to use.")
  181. end
  182. function dlg18(NPC, Spawn)
  183. FaceTarget(NPC, Spawn)
  184. PlayFlavor(NPC, "voiceover/english/voice_emotes/greetings/greetings_3_1034.mp3", "", "", 0, 0, Spawn)
  185. conversation = CreateConversation()
  186. AddConversationOption(conversation, "Yes I have. I learned the dervishes are working with the Deathfist orcs.", "dlg19")
  187. AddConversationOption(conversation, "No, not yet, I'll be back when I have.")
  188. StartConversation(conversation, NPC, Spawn, "Have you spoken with captain Vertas?")
  189. end
  190. function dlg19(NPC, Spawn)
  191. FaceTarget(NPC, Spawn)
  192. PlayFlavor(NPC, "brandus_levine/commonlands/quests/brandus_levine/brandus_levine030.mp3", "", "", 782844318, 2866426514, Spawn)
  193. conversation = CreateConversation()
  194. AddConversationOption(conversation, "It would be my pleasure.", "dlg20")
  195. AddConversationOption(conversation, "Only if you can continue to pay for my expensive services.", "dlg21")
  196. AddConversationOption(conversation, "I don't think so. I'm not really the enforcer type.")
  197. StartConversation(conversation, NPC, Spawn, "The Deathfist? You cannot be serious. Bah! That's probably where my shipment went, there's no way I'm getting that back by now. The orcs also have to pay for this, they had to know that shipment was mine. Do you mind playing enforcer again?")
  198. end
  199. function dlg20(NPC, Spawn)
  200. FaceTarget(NPC, Spawn)
  201. SetStepComplete(Spawn, FinishingtheNegotiations, 2)
  202. conversation = CreateConversation()
  203. AddConversationOption(conversation, "I'll return as soon as I find anything interesting from these orc runners.")
  204. StartConversation(conversation, NPC, Spawn, "Good, then I need you to find out what the connection is with with dervishes and the orcs. If you watch carefully you can sometimes see orc runners near the encampments in the Southern part of the Commonlands. I want the information they might be carrying. Let me know what you find.")
  205. end
  206. function dlg21(NPC, Spawn)
  207. FaceTarget(NPC, Spawn)
  208. conversation = CreateConversation()
  209. AddConversationOption(conversation, "Then we have a deal.", "dlg20")
  210. AddConversationOption(conversation, "On second thought, I think I'm done with this arrangement.")
  211. StartConversation(conversation, NPC, Spawn, "Of course, of course. We have a business deal and I'm willing to pay what is necessary to have this situation resolved as soon as possible.")
  212. end
  213. function dlg22(NPC, Spawn)
  214. FaceTarget(NPC, Spawn)
  215. PlayFlavor(NPC, "brandus_levine/commonlands/quests/brandus_levine/brandus_levine033.mp3", "", "", 1996105356, 11511501, Spawn)
  216. conversation = CreateConversation()
  217. AddConversationOption(conversation, "Here is the note I intercepted and had to decode.", "dlg23")
  218. AddConversationOption(conversation, "Enough to know I really dislike the Bloodskulls. And I found this note.", "dlg23")
  219. AddConversationOption(conversation, "Nothing yet. I'll be back later.")
  220. StartConversation(conversation, NPC, Spawn, "It's good to see you again. What did you learn from the orcs?")
  221. end
  222. function dlg23(NPC, Spawn)
  223. FaceTarget(NPC, Spawn)
  224. PlayFlavor(NPC, "brandus_levine/commonlands/quests/brandus_levine/brandus_levine034.mp3", "", "", 1083737725, 3622378931, Spawn)
  225. conversation = CreateConversation()
  226. AddConversationOption(conversation, "What about my reward for that information?", "dlg24")
  227. AddConversationOption(conversation, "I'm getting out of this now, goodbye.")
  228. StartConversation(conversation, NPC, Spawn, "Hrmmm. So they are having a meeting are they? Let me look into this and verify it isn't a trap. Come back when you're ready to crash their meeting.")
  229. end
  230. function dlg24(NPC, Spawn)
  231. FaceTarget(NPC, Spawn)
  232. SetStepComplete(Spawn, FinishingtheNegotiations, 6)
  233. PlayFlavor(NPC, "brandus_levine/commonlands/quests/brandus_levine/brandus_levine035.mp3", "", "", 2606991312, 3918213798, Spawn)
  234. conversation = CreateConversation()
  235. AddConversationOption(conversation, "Thank you. It's a pleasure doing business with you.")
  236. StartConversation(conversation, NPC, Spawn, "Ah yes, your reward. Here it is. Remember that I have more work and more rewards when you return.")
  237. end
  238. -- QUEST OFFER FUNCTIONS
  239. function offer2(NPC, Spawn)
  240. FaceTarget(NPC, Spawn)
  241. OfferQuest(NPC, Spawn, StartingtheNegotiations)
  242. end
  243. function offer3(NPC, Spawn)
  244. FaceTarget(NPC, Spawn)
  245. OfferQuest(NPC, Spawn, FinishingtheNegotiations)
  246. end
  247. function offer1(NPC, Spawn)
  248. FaceTarget(NPC, Spawn)
  249. OfferQuest(NPC, Spawn, TheMysteriousMissingShipment)
  250. end
  251. function respawn(NPC)
  252. spawn(NPC)
  253. end