LieutenantDelsun.lua 5.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111
  1. --[[
  2. Script Name : SpawnScripts/Caves/LieutenantDelsun.lua
  3. Script Purpose : Lieutenant Delsun <Qeynos Guard>
  4. Script Author : Scatman
  5. Script Date : 2009.10.18
  6. Script Notes :
  7. --]]
  8. local QUEST4_FROM_CONSULBREE = 230
  9. local QUEST_1 = 229
  10. function spawn(NPC)
  11. ProvidesQuest(NPC, QUEST_1)
  12. end
  13. function respawn(NPC)
  14. spawn(NPC)
  15. end
  16. function hailed(NPC, Spawn)
  17. FaceTarget(NPC, Spawn)
  18. conversation = CreateConversation()
  19. if HasCompletedQuest(Spawn, QUEST_1) then
  20. if HasCompletedQuest(Spawn, QUEST4_FROM_CONSULBREE) then
  21. PlayFlavor(NPC, "", "Thanks to you, the city of Qeynos will be safe from the Rockpaw gnolls. We are in your debt.", "salute", 0, 0, Spawn)
  22. else
  23. PlayFlavor(NPC, "voiceover/english/tutorial_revamp/lieutenant_delsun/qey_adv03_caves/qst_delsun_done_5c9845fb.mp3", "I appreciate the help. I am confident that soon you and Consul Bree will put an end to this threat.", "", 687681487, 1420406743, Spawn)
  24. end
  25. elseif HasQuest(Spawn, QUEST_1) then
  26. OnQuest1(NPC, Spawn, conversation)
  27. else
  28. WellMet(NPC, Spawn, conversation)
  29. end
  30. end
  31. ---------------------------------------------------------------------------------------------------------------------
  32. -- QUEST 1
  33. ---------------------------------------------------------------------------------------------------------------------
  34. function WellMet(NPC, Spawn, conversation)
  35. PlayFlavor(NPC, "voiceover/english/tutorial_revamp/lieutenant_delsun/qey_adv03_caves/quests/delsun/delsun_000.mp3", "", "", 633173859, 3236436843, Spawn)
  36. AddConversationOption(conversation, "What can I do to help?", "dlg_6_4")
  37. AddConversationOption(conversation, "What is going on down here?", "dlg_5_1")
  38. AddConversationOption(conversation, "I must go for now.")
  39. StartConversation(conversation, NPC, Spawn, "Well met. If you're here it's probably because you can help. I'm Lieutenant Delsun of the Qeynos Guard.")
  40. end
  41. function dlg_5_1(NPC, Spawn)
  42. FaceTarget(NPC, Spawn)
  43. conversation = CreateConversation()
  44. PlayFlavor(NPC, "voiceover/english/tutorial_revamp/lieutenant_delsun/qey_adv03_caves/quests/delsun/delsun_003.mp3", "", "", 3979540292, 2231912258, Spawn)
  45. AddConversationOption(conversation, "What are the gnolls planning?", "dlg_5_2")
  46. StartConversation(conversation, NPC, Spawn, "Many things, adventurer, many things. Consul Bree, Emma--over there--and I have been down here for some time now. Consul Bree was here by herself before that. The gnolls here are up to something big. I believe Consul Bree had the Queen herself request the presence of a large number of adventurers who showed great potential. Perhaps that is why you are here.")
  47. end
  48. function dlg_5_2(NPC, Spawn)
  49. FaceTarget(NPC, Spawn)
  50. conversation = CreateConversation()
  51. PlayFlavor(NPC, "voiceover/english/tutorial_revamp/lieutenant_delsun/qey_adv03_caves/quests/delsun/delsun_004.mp3", "", "", 2892187663, 805835825, Spawn)
  52. AddConversationOption(conversation, "What can I do to help?", "dlg_6_3")
  53. AddConversationOption(conversation, "I must go for now.")
  54. StartConversation(conversation, NPC, Spawn, "An attack. I do not know their intent. I do not believe they could ever defeat Qeynos in a war, but perhaps they are serving as a distraction. Either way, they must be stopped before it's too late. Consul Bree may know more of their plans.")
  55. end
  56. function dlg_6_3(NPC, Spawn)
  57. FaceTarget(NPC, Spawn)
  58. conversation = CreateConversation()
  59. PlayFlavor(NPC, "voiceover/english/tutorial_revamp/lieutenant_delsun/qey_adv03_caves/quests/delsun/delsun_001.mp3", "", "", 339232666, 1307734696, Spawn)
  60. AddConversationOption(conversation, "I will help you.", "dlg_6_4")
  61. AddConversationOption(conversation, "I must go for now.")
  62. StartConversation(conversation, NPC, Spawn, "Well. Consul Bree has a plan of attack that she may need help with. So speak to her if you want to offer your services. As for me, I am more interested in the gnolls than their plans. If you want to help me by taking some of them out, I will gladly accept it.")
  63. end
  64. function dlg_6_4(NPC, Spawn)
  65. FaceTarget(NPC, Spawn)
  66. conversation = CreateConversation()
  67. PlayFlavor(NPC, "voiceover/english/tutorial_revamp/lieutenant_delsun/qey_adv03_caves/quests/delsun/delsun_002.mp3", "", "", 455797705, 3616046354, Spawn)
  68. AddConversationOption(conversation, "I will do this.", "OfferQuest1")
  69. StartConversation(conversation, NPC, Spawn, "That is good to hear. I'd like you to help me take out the gnollish fighting force. Slay thirty gnolls within the caves. Make sure two of 'em are the Dustpaw armorers from the level above us, and five of 'em are the Rockpaw guards from the level above that. From the same level as the Rockpaw guards, take out five of the gnoll guardians known as alabaster behemoths. Return to me when you're done.")
  70. end
  71. function OfferQuest1(NPC, Spawn)
  72. FaceTarget(NPC, Spawn)
  73. OfferQuest(NPC, Spawn, QUEST_1)
  74. end
  75. function OnQuest1(NPC, Spawn, conversation)
  76. PlayFlavor(NPC, "voiceover/english/tutorial_revamp/lieutenant_delsun/qey_adv03_caves/quests/delsun/delsun_005.mp3", "", "", 2158069765, 3678013662, Spawn)
  77. if GetQuestStep(Spawn, QUEST_1) == 5 then
  78. AddConversationOption(conversation, "I have.", "dlg_21_1")
  79. else
  80. AddConversationOption(conversation, "Not yet.")
  81. end
  82. StartConversation(conversation, NPC, Spawn, "Have you done as I asked?")
  83. end
  84. function dlg_21_1(NPC, Spawn)
  85. SetStepComplete(Spawn, QUEST_1, 5)
  86. FaceTarget(NPC, Spawn)
  87. conversation = CreateConversation()
  88. PlayFlavor(NPC, "voiceover/english/tutorial_revamp/lieutenant_delsun/qey_adv03_caves/quests/delsun/delsun_006.mp3", "", "", 718413957, 2288759319, Spawn)
  89. AddConversationOption(conversation, "Thank you.")
  90. StartConversation(conversation, NPC, Spawn, "Good. Though we may not directly attack their production as Consul Bree does, we've done a great part in thinning out their armies. Take this, the Qeynos Guard puts aside such things for times like this. I believe you deserve it.")
  91. end