9
3

Kaman.lua 5.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121
  1. --[[
  2. Script Name : SpawnScripts/StonestairByway/Kaman.lua
  3. Script Purpose : Kaman
  4. Script Author : torsten
  5. Script Date : 2022.07.15
  6. Script Notes :
  7. --]]
  8. require "SpawnScripts/Generic/DialogModule"
  9. local Citizenship = 5859
  10. local CasingtheJoint = 5652
  11. function spawn(NPC)
  12. SetPlayerProximityFunction(NPC, 7, "InRange", "LeaveRange")
  13. end
  14. function respawn(NPC)
  15. spawn(NPC)
  16. end
  17. function InRange(NPC, Spawn)
  18. if HasQuest(Spawn,Citizenship) and GetQuestStep(Spawn,Citizenship)==4 then
  19. FaceTarget(NPC, Spawn)
  20. PlayFlavor(NPC, "voiceover/english/banker_quintius_calacicus/fprt_hood1/100_bankerquintiuscalacicus_housing_quest_1_22bf58bf.mp3", "Are you the one opening the new account?", "bye", 1249171681, 483955197, Spawn)
  21. end
  22. end
  23. function hailed(NPC, Spawn)
  24. if GetFactionAmount(Spawn,12) <0 then
  25. PlayFlavor(NPC, "", "", "shakefist", 0, 0, Spawn)
  26. elseif HasQuest(Spawn,Citizenship) and GetQuestStep(Spawn,Citizenship)==4 then
  27. Dialog2(NPC, Spawn)
  28. else
  29. Dialog1(NPC, Spawn)
  30. end
  31. end
  32. function Dialog1(NPC, Spawn)
  33. FaceTarget(NPC, Spawn)
  34. Dialog.New(NPC, Spawn)
  35. Dialog.AddDialog("Hello! Your valuables are safe with Kaman. Trust me. I'm the last of a long line of bankers. What guild do you belong to?")
  36. Dialog.AddVoiceover("voiceover/english/banker_kaman/fprt_hood02/bnk_banker_kaman.mp3", 1309348424, 2032495249)
  37. if GetQuestStep(Spawn, CasingtheJoint) == 1 then
  38. Dialog.AddOption("It is nice to see the bank so well protected.","Bank1")
  39. end
  40. Dialog.AddOption("Maybe another time.")
  41. Dialog.Start()
  42. end
  43. function Bank1(NPC, Spawn)
  44. FaceTarget(NPC, Spawn)
  45. Dialog.New(NPC, Spawn)
  46. Dialog.AddDialog("How kind of you! I'm used to sneers and hisses; so kind words are music to my ears. I'm trying to build up the trust of the people ... ever since that rumor it's been very difficult ...")
  47. Dialog.AddVoiceover("voiceover/english/banker_kaman/fprt_hood04/quests/luciusvulso/kaman_lucius_x1_initial.mp3", 1416971542, 1234122783)
  48. PlayFlavor(NPC, "", "", "smirk", 0, 0, Spawn)
  49. Dialog.AddOption("I'm sorry... but what rumor?","Bank2")
  50. Dialog.Start()
  51. end
  52. function Bank2(NPC, Spawn)
  53. FaceTarget(NPC, Spawn)
  54. Dialog.New(NPC, Spawn)
  55. Dialog.AddDialog("Ah ... Not from around here, are ya? Someone is spreading the rumor that our vault isn't secure. They say you can tunnel in the vault from the sewers below. But it's preposterous, I tell you, just preposterous! Sorry. I don't mean to digress, friend. Now, are you making a deposit or withdrawal?")
  56. Dialog.AddVoiceover("voiceover/english/banker_kaman/fprt_hood04/quests/luciusvulso/kaman_lucius_x1_initial2.mp3", 2499658980, 1146756071)
  57. PlayFlavor(NPC, "", "", "tapfoot", 0, 0, Spawn)
  58. Dialog.AddOption("Nothing right now. Thank you.")
  59. SetStepComplete(Spawn, CasingtheJoint, 1)
  60. Dialog.Start()
  61. end
  62. function Dialog2(NPC, Spawn)
  63. FaceTarget(NPC, Spawn)
  64. Dialog.New(NPC, Spawn)
  65. Dialog.AddDialog("Yes, you look like the one Valthun described. Before we can open your account, we need some information from you. What is your name?")
  66. Dialog.AddVoiceover("voiceover/english/banker_kaman/fprt_hood02/bnk_banker_kaman006.mp3", 1584899105, 4177190820)
  67. Dialog.AddOption(""..GetName(Spawn).."","Dialog2a")
  68. Dialog.Start()
  69. end
  70. function Dialog2a(NPC, Spawn)
  71. FaceTarget(NPC, Spawn)
  72. Dialog.New(NPC, Spawn)
  73. Dialog.AddDialog("What is your occupation?")
  74. Dialog.AddVoiceover("voiceover/english/banker_kaman/fprt_hood02/bnk_banker_kaman007.mp3", 491324789, 1115007085)
  75. Dialog.AddOption("Adventurer","Dialog2b")
  76. Dialog.AddOption("Crafter","Dialog2b")
  77. if GetRace(Spawn)==3 then
  78. Dialog.AddOption("Seeker? Of knowledge, obviously.","Dialog2b")
  79. elseif GetRace(Spawn)==11 then
  80. Dialog.AddOption("If you put down rat catcher I'll...","Dialog2b")
  81. end
  82. Dialog.Start()
  83. end
  84. function Dialog2b(NPC, Spawn)
  85. FaceTarget(NPC, Spawn)
  86. Dialog.New(NPC, Spawn)
  87. Dialog.AddDialog("Any surviving relatives, do you ever leave your house unarmed, and are you a deep sleeper?")
  88. Dialog.AddVoiceover("voiceover/english/banker_kaman/fprt_hood02/bnk_banker_kaman008.mp3", 3429718492, 1776251277)
  89. PlayFlavor(NPC, "", "", "nod", 0, 0, Spawn)
  90. Dialog.AddOption("No, no, and no.","Dialog2c")
  91. Dialog.AddOption("[Lie] No, no, and no.","Dialog2c")
  92. Dialog.AddOption("This does sound concerning!... no!","Dialog2c")
  93. Dialog.Start()
  94. end
  95. function Dialog2c(NPC, Spawn)
  96. if HasQuest(Spawn,Citizenship) and GetQuestStep(Spawn,Citizenship)==4 then
  97. SetStepComplete(Spawn, Citizenship,4)
  98. end
  99. FaceTarget(NPC, Spawn)
  100. Dialog.New(NPC, Spawn)
  101. Dialog.AddDialog("How convenient for you. Very well ... a place for you within the Freeport Reserve vaults have been set aside . Feel free to deposit large amounts of coin or valuable artifacts with us anytime. We'll be sure to keep it ... safe. Will there anything else?")
  102. Dialog.AddVoiceover("voiceover/english/banker_kaman/fprt_hood02/bnk_banker_kaman009.mp3", 3192376805, 46493799)
  103. PlayFlavor(NPC, "", "", "smirk", 0, 0, Spawn)
  104. Dialog.AddOption("Not right now.")
  105. Dialog.Start()
  106. end