ShaeAhla.lua 4.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115
  1. --[[
  2. Script Name : SpawnScripts/Castleview/ShaeAhla.lua
  3. Script Purpose : Shae'Ahla
  4. Script Author : Scatman
  5. Script Date : 2009.10.03
  6. Script Notes :
  7. --]]
  8. dofile("SpawnScripts/Generic/GenericVoiceOvers.lua")
  9. local TargetingCorruption = 225
  10. function spawn(NPC)
  11. SetInfoStructString(NPC, "action_state", "ponder")
  12. end
  13. function respawn(NPC)
  14. spawn(NPC)
  15. end
  16. function hailed(NPC, Spawn)
  17. FaceTarget(NPC, Spawn)
  18. conversation = CreateConversation()
  19. GenericHail(NPC, Spawn)
  20. if HasQuest(Spawn, TargetingCorruption) and GetQuestStep(Spawn, TargetingCorruption) == 1 then
  21. WherePainGose(NPC, Spawn, conversation)
  22. else
  23. RandomChat(NPC, Spawn)
  24. end
  25. end
  26. function RandomChat(NPC, Spawn)
  27. local choice = math.random(1, 3)
  28. if choice == 1 then
  29. Say(NPC, "To be lost is to avoid being found.", Spawn)
  30. elseif choice == 2 then
  31. Say(NPC, "A life cut off from your senses is no life at all.", Spawn)
  32. elseif choice == 3 then
  33. Say(NPC, "If you do not seek out pain, it will still find you.", Spawn)
  34. end
  35. end
  36. function WherePainGose(NPC, Spawn, conversation)
  37. PlayFlavor(NPC, "voiceover/english/tutorial_revamp/shae_ahla/qey_village04/quests/sheaahla/sheaahla000.mp3", "", "", 4274300137, 4254333791, Spawn)
  38. AddConversationOption(conversation, "Vindain sent me, I need your help.", "dlg_20_3")
  39. AddConversationOption(conversation, "What does that mean?", "dlg_20_1")
  40. AddConversationOption(conversation, "I agree.")
  41. StartConversation(conversation, NPC, Spawn, "Where pain goes, all sentient beings tend to follow.")
  42. end
  43. function dlg_20_1(NPC, Spawn)
  44. FaceTarget(NPC, Spawn)
  45. conversation = CreateConversation()
  46. PlayFlavor(NPC, "voiceover/english/tutorial_revamp/shae_ahla/qey_village04/quests/sheaahla/sheaahla001.mp3", "", "", 3064229666, 2077041902, Spawn)
  47. AddConversationOption(conversation, "That is a rather pessimistic view.", "dlg_20_2")
  48. AddConversationOption(conversation, "That makes sense.", "RareYouAndI")
  49. StartConversation(conversation, NPC, Spawn, "It means that we--elves, humans, gnomes, trolls, all races--blindly plunge ourselves into darkness and chaos. We do not 'intend' to do this, but without fail we do.")
  50. end
  51. function RareYouAndI(NPC, Spawn)
  52. FaceTarget(NPC, Spawn)
  53. conversation = CreateConversation()
  54. AddConversationOption(conversation, "Vindain sent me, I need your help.", "dlg_20_3")
  55. StartConversation(conversation, NPC, Spawn, "We are rare, you and I. Why do you come to me?")
  56. end
  57. function dlg_20_2(NPC, Spawn)
  58. FaceTarget(NPC, Spawn)
  59. conversation = CreateConversation()
  60. PlayFlavor(NPC, "voiceover/english/tutorial_revamp/shae_ahla/qey_village04/quests/sheaahla/sheaahla003.mp3", "", "", 3991540822, 537258105, Spawn)
  61. AddConversationOption(conversation, "Vindain sent me, I need your help.", "dlg_20_3")
  62. StartConversation(conversation, NPC, Spawn, "Worlds that are lost in strife and pain do tend to produce pessimists. Tell me, why are you here?")
  63. end
  64. function dlg_20_3(NPC, Spawn)
  65. FaceTarget(NPC, Spawn)
  66. conversation = CreateConversation()
  67. PlayFlavor(NPC, "voiceover/english/tutorial_revamp/shae_ahla/qey_village04/quests/sheaahla/sheaahla004.mp3", "", "", 1399643965, 359394892, Spawn)
  68. AddConversationOption(conversation, "I was planting Green Wisps here in Castleview Hamlet. One wisp came alive and attacked me.", "dlg_21_2")
  69. StartConversation(conversation, NPC, Spawn, "What do you require?")
  70. end
  71. function dlg_21_2(NPC, Spawn)
  72. FaceTarget(NPC, Spawn)
  73. conversation = CreateConversation()
  74. PlayFlavor(NPC, "voiceover/english/tutorial_revamp/shae_ahla/qey_village04/quests/sheaahla/sheaahla005.mp3", "", "", 2035237242, 2834747464, Spawn)
  75. AddConversationOption(conversation, "Can you help?", "dlg_21_3")
  76. StartConversation(conversation, NPC, Spawn, "You see? Corruption is everywhere.")
  77. end
  78. function dlg_21_3(NPC, Spawn)
  79. FaceTarget(NPC, Spawn)
  80. conversation = CreateConversation()
  81. PlayFlavor(NPC, "voiceover/english/tutorial_revamp/shae_ahla/qey_village04/quests/sheaahla/sheaahla006.mp3", "", "", 1528947055, 3565435961, Spawn)
  82. AddConversationOption(conversation, "All right.", "dlg_21_4")
  83. StartConversation(conversation, NPC, Spawn, "Yes, I can help. Please, give me your hand.")
  84. end
  85. function dlg_21_4(NPC, Spawn)
  86. SetStepComplete(Spawn, TargetingCorruption, 1)
  87. FaceTarget(NPC, Spawn)
  88. conversation = CreateConversation()
  89. PlayFlavor(NPC, "voiceover/english/tutorial_revamp/shae_ahla/qey_village04/quests/sheaahla/sheaahla007.mp3", "", "", 2043489074, 1826207926, Spawn)
  90. AddConversationOption(conversation, "Thank you, Shae'Ahla.")
  91. StartConversation(conversation, NPC, Spawn, "It is done. Your fingers are blessed in a way that will counter the corruption, simply rub the leaves of the plant to cleanse it.")
  92. end