KallonEbbtide.lua 21 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337
  1. --[[
  2. Script Name : SpawnScripts/SinkingSands/KallonEbbtide.lua
  3. Script Author : premierio015
  4. Script Date : 2023.12.15 06:12:03
  5. Script Purpose :
  6. :
  7. --]]
  8. require "SpawnScripts/Generic/DialogModule"
  9. local KallonsVengeance = 5938 -- Kallon's Vengeance Quest ID
  10. function spawn(NPC)
  11. ProvidesQuest(NPC, KallonsVengeance)
  12. end
  13. function hailed(NPC, Spawn)
  14. FaceTarget(NPC, Spawn)
  15. if not HasQuest(Spawn, KallonsVengeance) and not HasCompletedQuest(Spawn, KallonsVengeance) then
  16. Option0(NPC, Spawn)
  17. elseif GetQuestStep(Spawn, KallonsVengeance) == 1 or GetQuestStep(Spawn, KallonsVengeance) == 2 or GetQuestStep(Spawn, KallonsVengeance) == 3 or GetQuestStep(Spawn, KallonsVengeance) == 4 or GetQuestStep(Spawn, KallonsVengeance) == 5 then
  18. KallonsVengeanceProgress(NPC, Spawn)
  19. elseif HasCompletedQuest(Spawn, KallonsVengeance) then
  20. OptionCompleted(NPC, Spawn)
  21. end
  22. end
  23. function Option0(NPC, Spawn)
  24. FaceTarget(NPC, Spawn)
  25. Dialog.New(NPC, Spawn)
  26. Dialog.AddDialog("Ah, a new face that looks eager to explore these lands! If you're looking for gainful employment, the Courts of Maj'Dul are looking for foreign adventurers to strengthen their ranks.")
  27. Dialog.AddOption("Hello. I don't believe we've met, who are you?", "Option2")
  28. Dialog.AddOption("What are the Courts of Maj'Dul?", "Option1")
  29. Dialog.AddOption("Not interested, I will be on my way now.")
  30. Dialog.AddVoiceover("voiceover/english/voice_emotes/greetings/greetings_1_1022.mp3", 0, 0)
  31. Dialog.Start()
  32. end
  33. function Option1(NPC, Spawn)
  34. FaceTarget(NPC, Spawn)
  35. Dialog.New(NPC, Spawn)
  36. Dialog.AddDialog("The courts of Maj'Dul are three separate factions within the city that vie for power over the remnants of the Dervish empire. They have each established an outpost at the docks, and their goal is to attract new arrivals to their competing causes. Mahir Lu'ay represents the Court of the Blade, Thara Bashirah represents the Court of the Coin, and Taj As'ad represents the Court of Truth. I encourage you to converse with these individuals, as collectively the courts are the most powerful political force in these lands.")
  37. Dialog.AddOption("I would like to hear more of your journey through these lands.", "Option4")
  38. Dialog.AddOption("I appreciate the advice, but I must take my leave.")
  39. Dialog.Start()
  40. end
  41. function Option2(NPC, Spawn)
  42. FaceTarget(NPC, Spawn)
  43. Dialog.New(NPC, Spawn)
  44. Dialog.AddDialog("My name is Kallon Ebbtide, and I have had many adventures in these lands. Would you like to hear my tale? Perhaps, you would rather hear of the different lands or people? Either way, I would be honored to help a fellow adventurer with whatever information I may have.")
  45. Dialog.AddOption("I would like to hear the tale of your personal adventures.", "Option5")
  46. Dialog.AddOption("Another time, perhaps.")
  47. Dialog.Start()
  48. end
  49. function Option4(NPC, Spawn)
  50. FaceTarget(NPC, Spawn)
  51. Dialog.New(NPC, Spawn)
  52. Dialog.AddDialog("My name is Kallon Ebbtide, and I have had many adventures in these lands. Would you like to hear my tale? Perhaps, you would rather hear of the different lands or people? Either way, I would be honored to help a fellow adventurer with whatever information I may have.")
  53. Dialog.AddOption("I would like to hear the tale of your personal adventures.", "Option5")
  54. Dialog.AddOption("I would like to hear more about the lands of this foreign shore.", "Option10")
  55. Dialog.AddOption("I would like to hear more about the people of this land.", "Option21")
  56. Dialog.AddOption("Another time, perhaps.")
  57. Dialog.Start()
  58. end
  59. function Option5(NPC, Spawn)
  60. FaceTarget(NPC, Spawn)
  61. Dialog.New(NPC, Spawn)
  62. Dialog.AddDialog("Much like you, I came here searching for adventure and riches. What I found was a harsh and brutal land with an equally harsh people inhabiting it. My companions and I arrived and immediately sought a guide to take us to Maj'Dul. We found someone at the hunter camp further north of the nomad camp, and he agreed to take us.")
  63. Dialog.AddOption("Please continue your story.", "Option6")
  64. Dialog.AddOption("Unfortunately, I must take my leave.")
  65. Dialog.Start()
  66. end
  67. function Option6(NPC, Spawn)
  68. FaceTarget(NPC, Spawn)
  69. Dialog.New(NPC, Spawn)
  70. Dialog.AddDialog("This guide asked us to meet him at the oasis nearby. In reality, this person was leading us into a trap for his bandit comrades. We were ambushed at the oasis by a man named Fasul and his bandits. We resisted, and in the course of the fight all of my companions were slain and I was unconscious and left for dead.")
  71. Dialog.AddOption("That is horrible! How did you survive?", "Option7")
  72. Dialog.AddOption("That is an unfortunate tale, but I must leave now.")
  73. Dialog.Start()
  74. end
  75. function Option7(NPC, Spawn)
  76. FaceTarget(NPC, Spawn)
  77. Dialog.New(NPC, Spawn)
  78. Dialog.AddDialog("When I awoke, I had been saved by a merchant traveling to Maj'Dul. In gratitude, I offered to serve this merchant. For the next few moons, I traveled throughout this realm as the merchant's servant. Very recently, he became deathly ill and as a gesture of kindness released me from my service. I have now decided to return home, and I am working as an emissary of the courts for new arrivals to earn my fare home.")
  79. if not HasQuest(Spawn, KallonsVengeance) and not HasCompletedQuest(Spawn, KallonsVengeance) then
  80. Dialog.AddOption("What about this bandit? Did you ever avenge your comrades?", "Option9")
  81. end
  82. Dialog.AddOption("Please elaborate on these courts.", "Option8")
  83. Dialog.AddOption("I would like to hear more of your stories.", "Option2")
  84. Dialog.AddOption("An interesting story, but I must take my leave.")
  85. Dialog.Start()
  86. end
  87. function Option8(NPC, Spawn)
  88. FaceTarget(NPC, Spawn)
  89. Dialog.New(NPC, Spawn)
  90. Dialog.AddDialog("The courts of Maj'Dul are three separate factions within the city that vie for power over the remnants of the Dervish empire. They have each established an outpost at the docks, and their goal is to attract new arrivals to their competing causes. Mahir Lu'ay represents the Court of the Blade, Thara Bashirah represents the Court of the Coin, and Taj As'ad represents the Court of Truth. I encourage you to converse with these individuals, as collectively the courts are the most powerful political force in these lands.")
  91. Dialog.AddOption("I would like to hear more of your journey through these lands.", "Option4")
  92. Dialog.AddOption("I appreciate the advice, but I must take my leave.")
  93. Dialog.Start()
  94. end
  95. function Option9(NPC, Spawn)
  96. FaceTarget(NPC, Spawn)
  97. Dialog.New(NPC, Spawn)
  98. Dialog.AddDialog("One last thing holds me to this realm. I never found Fasul to exact vengeance for my fallen friends. I expect he is still a menace to new arrivals and nomad merchants alike. Would you be interested in pursuing this man?")
  99. Dialog.AddOption("Yes, I will be glad to act your stead in this matter.", "offer")
  100. Dialog.AddOption("I am not interested in fighting someone else's battle.")
  101. Dialog.Start()
  102. end
  103. function Option10(NPC, Spawn)
  104. FaceTarget(NPC, Spawn)
  105. Dialog.New(NPC, Spawn)
  106. Dialog.AddDialog("The Desert of Ro is a harsh and unyielding place. The only major city remaining after the Shattering is Maj'Dul, and it is the seat of the Dervish empire. There are two distinct regions, both different in their harsh landscape. You have arrived here in the Sinking Sands, name for the large area of sandy dunes to our west. Far to the west, beyond the dunes, lie the Pillars of Flame.")
  107. Dialog.AddOption("I would like to hear more about the city of Maj'Dul.", "Option11")
  108. Dialog.AddOption("I am interested in hearing more about the Sinking Sands.", "Option17")
  109. Dialog.AddOption("I am interested in hearing about the Pillars of Flame.", "Option19")
  110. Dialog.AddOption("I would rather talk about something else.", "Option4")
  111. Dialog.AddOption("I do not have time for further tales.")
  112. Dialog.Start()
  113. end
  114. function Option11(NPC, Spawn)
  115. FaceTarget(NPC, Spawn)
  116. Dialog.New(NPC, Spawn)
  117. Dialog.AddDialog("Maj'Dul is the only city in the Desert of Ro. It was created by the first sultan of the Dervish empire, Ahkari. It is now a city of intrigue and danger. After Ahkari's death, his sons could not agree on who should lead, so they formed the Courts of Maj'Dul from their own followers and began to vie for power over the Dervish Empire.")
  118. Dialog.AddOption("What are these Courts?", "Option12")
  119. Dialog.AddOption("How did Ahkari die?", "Option16")
  120. Dialog.AddOption("I would rather hear about other tales.", "Option4")
  121. Dialog.Start()
  122. end
  123. function Option12(NPC, Spawn)
  124. FaceTarget(NPC, Spawn)
  125. Dialog.New(NPC, Spawn)
  126. Dialog.AddDialog("The Courts of Maj'Dul were originally distinct sects, each formed and controlled by a son of Ahkari. After Ahkari's death, each son established a court based on his sect. These are the Court of the Blade, the Court of the Coin, and the Court of Truth.")
  127. Dialog.AddOption("I would like to hear more about the Court of the Blade.", "Option10")
  128. Dialog.AddOption("I am interested in hearing more about the Court of the Coin.", "Option14")
  129. Dialog.AddOption("Please tell me more about the Court of Truth.", "Option15")
  130. Dialog.AddOption("What about the emissaries of the Courts at the docks?", "Option1")
  131. Dialog.AddOption("I would like to hear more about Maj'Dul", "Option11")
  132. Dialog.AddOption("I must take my leave, I will return another time.")
  133. Dialog.Start()
  134. end
  135. function Option13(NPC, Spawn)
  136. FaceTarget(NPC, Spawn)
  137. Dialog.New(NPC, Spawn)
  138. Dialog.AddDialog("The Court of the Blade, currently headed by Dukarem, believes they must lead the Dervish empire through military force to expand it. Dukarem succeeded his father, Dukar, as the leader. Dukarem's son, Dukaris, is rumored to be quite the hero and is called the Champion of the People.")
  139. Dialog.AddOption("I would like to hear more about the Courts.", "Option12")
  140. Dialog.AddOption("I need to depart. Perhaps I will have time for tales later.")
  141. Dialog.Start()
  142. end
  143. function Option14(NPC, Spawn)
  144. FaceTarget(NPC, Spawn)
  145. Dialog.New(NPC, Spawn)
  146. Dialog.AddDialog("The Court of the Coin, headed by Neriph, seeks to lead and revive the Dervish Empire through commerce and trading. It is rumored that Neriph was unprepared to lead the Coin when his father, Omren, died. They say that he depends heavily upon his advisors.")
  147. Dialog.AddOption("I am interested in hearing more about these Courts.", "Option12")
  148. Dialog.AddOption("Unfortunately, I need to depart.")
  149. Dialog.Start()
  150. end
  151. function Option15(NPC, Spawn)
  152. FaceTarget(NPC, Spawn)
  153. Dialog.New(NPC, Spawn)
  154. Dialog.AddDialog("The Court of Truth, headed by Ishara, seeks to control the Dervish empire through its complex judicial system, and they are also the caretakers of all essential knowledge. Ishara became the caliph of Truth when his father, Ishti, was exiled. It is rumored that the prized aqueducts in Maj'Dul are having problems, and Ishara is looking for help in solving this.")
  155. Dialog.AddOption("Please tell me more about the Courts of Maj'Dul.", "Option12")
  156. Dialog.AddOption("I will come back for more tales another time.")
  157. Dialog.Start()
  158. end
  159. function Option16(NPC, Spawn)
  160. FaceTarget(NPC, Spawn)
  161. Dialog.New(NPC, Spawn)
  162. Dialog.AddDialog("Maj'Dul was originally a fortress for Ahkari. As he gathered the various tribes of Dervin under his banner, Maj'Dul slowly became the center of the Dervish empire. It is rumored that Ahkari went insane and leapt from the palace walls to his death. I did not find out exactly what happened, but Akhari's death was the event that led to the formation of the Courts and to the decline and instability of the Dervish empire.")
  163. Dialog.AddOption("I would like to hear more about Maj'Dul.", "Option11")
  164. Dialog.AddOption("I must go. Perhaps I can hear your tales another time.")
  165. Dialog.Start()
  166. end
  167. function Option17(NPC, Spawn)
  168. FaceTarget(NPC, Spawn)
  169. Dialog.New(NPC, Spawn)
  170. Dialog.AddDialog("The Sinking Sands is the name of this part of the Desert of Ro. It is dominated by the Stilled Sea, a vast landscape of sandy dunes that stretches to our west and north. The route to Maj'Dul starts at the Oasis of Marr nearby and winds along the southwest border of this sea of sand. Within the western area of the Stilled Sea there are two large oases called the Twin Tears. The beaches around us are the eastern edge of the Stilled Sea, and far south along these beaches stands Onerock Isle.")
  171. Dialog.AddOption("What inhabits the Sinking Sands?", "Option18")
  172. Dialog.Start()
  173. end
  174. function Option18(NPC, Spawn)
  175. FaceTarget(NPC, Spawn)
  176. Dialog.New(NPC, Spawn)
  177. Dialog.AddDialog("It is the home to various denizens. Besides the ferocious crocodiles along the beach and in the caverns nearby, the Rujarkian orcs and Alliz Raef Ew lizardmen harass any who travel the route to Maj'Dul. There are also the Anaz Mal gnolls who make their home in ancient tombs near one of the Twin Tears. Recent disturbing reports indicate that undead roam the deeper areas of the Stilled Sea.")
  178. Dialog.AddOption("What of the courts' presence in the Sinking Sands?", "Option8")
  179. Dialog.AddOption("I would like to hear more of the regions that make up the Desert of Ro.", "Option10")
  180. Dialog.AddOption("I do not have time for further tales.")
  181. Dialog.Start()
  182. end
  183. function Option19(NPC, Spawn)
  184. FaceTarget(NPC, Spawn)
  185. Dialog.New(NPC, Spawn)
  186. Dialog.AddDialog("The Pillars of Flame are located west of us, and northwest of Maj'Dul. Both the Dervish and native denizens war over control of the various plateaus of the region. T'Narev, the home of the Ashen Order monks, is located on the northeastern plateaus. The Ortallian tribe of nomads is located to the south while the Char'gin tribe makes its home on a northwestern plateau, and the Swiftriders have a base camp within the region.")
  187. Dialog.AddOption("What of the threats native to this area?", "Option20")
  188. Dialog.AddOption("I would rather talk about other places.", "Option10")
  189. Dialog.AddOption("I must take my leave.")
  190. Dialog.Start()
  191. end
  192. function Option20(NPC, Spawn)
  193. FaceTarget(NPC, Spawn)
  194. Dialog.New(NPC, Spawn)
  195. Dialog.AddDialog("There are various threats in the Pillars of Flame. The goblins dominate the eastern areas and plateaus while the harpies and giants occupy the western plateaus and canyons. These groups are constantly vying for control of the region as well as harassing the nomads and Dervish in the area. The only other significant threats are the cyclopes to the south, and the mysterious naga, of which I know very little, that occupy an island plateau in the north.")
  196. Dialog.AddOption("I would like to hear of other sights in the Desert of Ro.", "Option10")
  197. Dialog.AddOption("I must be on my way.")
  198. Dialog.Start()
  199. end
  200. function Option21(NPC, Spawn)
  201. FaceTarget(NPC, Spawn)
  202. Dialog.New(NPC, Spawn)
  203. Dialog.AddDialog("The Desert of Ro is home to many types of beings, but the dominant civilization and culture is the Dervish empire. This empire was formed from the various nomad tribes and Dervish bandits that inhabited this region well before the Shattering. Interestingly, some nomads have remained independent with tribes in both the Sinking Sands and Pillars of Flame.")
  204. Dialog.AddOption("I am interested in hearing more about the Dervish empire, specifically Maj'Dul.", "Option11")
  205. Dialog.AddOption("I would like to hear more about these independent nomad tribes.", "Option22")
  206. Dialog.AddOption("I would like to hear your assessment of major threats in the Desert of Ro.", "Option24")
  207. Dialog.AddOption("I must take my leave.")
  208. Dialog.Start()
  209. end
  210. function Option22(NPC, Spawn)
  211. FaceTarget(NPC, Spawn)
  212. Dialog.New(NPC, Spawn)
  213. Dialog.AddDialog("Some of the nomads in these lands did not join the Dervish empire, or they split off after the death of Ahkari. The Sinking Sands is the home of the Raj'Dur and Hizite tribes of nomads. The Raj'Dur tribe established a crocodile hunter camp north of these docks, but I do not believe that this is their only occupation. The Hizite tribe seems to be peaceful shepherds, occupying the camp to the west of the docks near the Oasis of Marr. Be wary of your dealings with either tribe, as they have no fondness for one another.")
  214. Dialog.AddOption("What of the other tribes?", "Option23")
  215. Dialog.AddOption("It sounds like you don't trust the Raj'Dur.", "Option5")
  216. Dialog.AddOption("I would like to hear about other people in these lands.", "Option19")
  217. Dialog.AddOption("I must leave and take care of other business")
  218. Dialog.Start()
  219. end
  220. function Option23(NPC, Spawn)
  221. FaceTarget(NPC, Spawn)
  222. Dialog.New(NPC, Spawn)
  223. Dialog.AddDialog("There are also two tribes located in the Pillars of Flame. The Char'Gin once occupied and mined in the clefts and valleys that the Rujarkian orcs now control, and they were forced to establish a foothold in the northern plateaus as fishermen. The Ortallians are religious zealots of Solusek Ro. I would be very careful of those fanatics. You may also come across the Swiftriders. They are a loose band of nomads from all tribes that have cast off their individual affiliations and now deliver goods from one tribe to another.")
  224. Dialog.AddOption("I would like to hear about other people in these lands.", "Option16")
  225. Dialog.AddOption("I will come back for more tales another time.")
  226. Dialog.Start()
  227. end
  228. function Option24(NPC, Spawn)
  229. FaceTarget(NPC, Spawn)
  230. Dialog.New(NPC, Spawn)
  231. Dialog.AddDialog("It is my belief that the Courts' in-fighting is the most dangerous threat to themselves and foreigners alike. If you refer to external threats, however, then the Rujarkian orcs occupy and control all that is south of Maj'Dul. There is also a significant presence of gnolls, lizardmen, goblins, harpies, and various giant-kin that are a constant threat to travelers going to and from Maj'Dul. However, I believe there are also unseen threats lurking.")
  232. Dialog.AddOption("What do you mean?", "Option25")
  233. Dialog.AddOption("I would like to hear about other people in these lands.", "Option21")
  234. Dialog.AddOption("I don't have time for your idle speculations.")
  235. Dialog.Start()
  236. end
  237. function Option25(NPC, Spawn)
  238. FaceTarget(NPC, Spawn)
  239. Dialog.New(NPC, Spawn)
  240. Dialog.AddDialog("There are myths and stories that seem to have some basis in fact. The recent presence of undead in deeper areas of the Stilled Sea definitely bode ill for the Dervish Empire. I've seen the floating citadel rumored to be controlled by the mysterious djinn, and no one knows what their purpose is within this desert. Lastly, I've heard rumors of a dragon of gold or silver hue making its home in the Desert of Ro. Oddly, no one agrees on whether it is gold or silver, but everyone agrees that it is no myth.")
  241. Dialog.AddOption("I would like to hear more about people in these lands.", "Option21")
  242. Dialog.AddOption("I must take my leave.")
  243. Dialog.Start()
  244. end
  245. function offer(NPC, Spawn)
  246. OfferQuest(NPC, Spawn, KallonsVengeance)
  247. end
  248. function KallonsVengeanceProgress(NPC, Spawn)
  249. Dialog.New(NPC, Spawn)
  250. Dialog.AddDialog("Welcome... back, adventurer! Did you find the bandits?")
  251. Dialog.AddOption("Unfortunately, no. I would like to hear of your adventures again, please.", "Option4")
  252. if GetQuestStep(Spawn, KallonsVengeance) == 5 then
  253. Dialog.AddOption("Yes, I have avenged your fallen comrades! You can now leave these lands with a clear conscience.", "OptionFinish")
  254. end
  255. Dialog.AddOption("No, I am still searching for the bandits.")
  256. Dialog.AddVoiceover("voiceover/english/voice_emotes/greetings/greetings_1_1022.mp3", 0, 0)
  257. Dialog.Start()
  258. end
  259. function OptionFinish(NPC, Spawn)
  260. SetStepComplete(Spawn, KallonsVengeance, 5)
  261. FaceTarget(NPC, Spawn)
  262. Dialog.New(NPC, Spawn)
  263. Dialog.AddDialog("Thank you, my friends! I can now leave these lands without guilt since my comrades have been avenged. I still need to finish earning my passage, but this news makes that a small burden. Thank you again. I shall remember your kindness.")
  264. Dialog.AddOption("You're welcome. I would be interesed in hearing about the Court's emissaries in Sinking Sands.", "Option2")
  265. Dialog.AddOption("I am glad i could help. I would like to hear more of your tales.", "Option2")
  266. Dialog.AddOption("Good luck in your endeavor. Perhaps we'll meet again.")
  267. Dialog.Start()
  268. end
  269. function OptionCompleted(NPC, Spawn)
  270. FaceTarget(NPC, Spawn)
  271. Dialog.New(NPC, Spawn)
  272. Dialog.AddDialog("Welcome back, my friend. As you can see, I am still working to cover my fees for the voyage home. How fare your adventures?")
  273. Dialog.AddOption("I am exploring places and meeting people you might have mentioned. May I hear of your adventures again?", "Option2")
  274. Dialog.AddOption("It is good to see you, Kallon. Unfortunately, I do not have time to chat.")
  275. Dialog.Start()
  276. end
  277. function respawn(NPC)
  278. spawn(NPC)
  279. end