TrainerNhilzyneBMyar.lua 15 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248
  1. --[[
  2. Script Name : SpawnScripts/Darklight/TrainerNhilzyneBMyar.lua
  3. Script Purpose : Trainer Nhilzyne B'Myar <Combat Trainer>
  4. Script Author : Scatman
  5. Script Date : 2009.09.05
  6. Script Notes :
  7. --]]
  8. dofile("SpawnScripts/Generic/GenericVoiceOvers.lua")
  9. function spawn(NPC)
  10. end
  11. function respawn(NPC)
  12. spawn(NPC)
  13. end
  14. function hailed(NPC, Spawn)
  15. FaceTarget(NPC, Spawn)
  16. conversation = CreateConversation()
  17. GenericHail(NPC, Spawn)
  18. AddConversationOption(conversation, "Teach me the basics of combat.", "dlg_2_1")
  19. AddConversationOption(conversation, "Teach me more advanced aspects of combat.", "dlg_2_17")
  20. AddConversationOption(conversation, "I'll come back later.")
  21. StartConversation(conversation, NPC, Spawn, "Hello there. I'm here to teach folks the finer points of combat. I don't like to get into a fight, but if I do, I prefer to win. Know what I mean?")
  22. end
  23. function dlg_2_1(NPC, Spawn)
  24. FaceTarget(NPC, Spawn)
  25. conversation = CreateConversation()
  26. AddConversationOption(conversation, "Tell me how to begin a fight.", "dlg_2_2")
  27. AddConversationOption(conversation, "Tell me about melee combat.", "dlg_2_5")
  28. AddConversationOption(conversation, "Tell me about ranged combat.", "dlg_2_7")
  29. AddConversationOption(conversation, "What kind of rewards can I earn in battle?", "dlg_2_14")
  30. AddConversationOption(conversation, "Teach me more advanced aspects of combat.", "dlg_2_17")
  31. AddConversationOption(conversation, "I'll come back later.")
  32. StartConversation(conversation, NPC, Spawn, "There are many different elements that go into successful combat. I can teach you a few of the basics, such as how to begin a fight, the difference between melee and ranged combat, and earning rewards for victory.")
  33. end
  34. function dlg_2_2(NPC, Spawn)
  35. FaceTarget(NPC, Spawn)
  36. conversation = CreateConversation()
  37. AddConversationOption(conversation, "How do I begin the battle?", "dlg_2_3")
  38. StartConversation(conversation, NPC, Spawn, "Starting combat is easy. Just use your mouse pointer to left-click on an opponent. Its name will appear in the Target window in the upper left of your screen. You can also use the Tab key to cycle through nearby targets or the F8 key to select your closest enemy.")
  39. end
  40. function dlg_2_3(NPC, Spawn)
  41. FaceTarget(NPC, Spawn)
  42. conversation = CreateConversation()
  43. AddConversationOption(conversation, "So I can fight anyone or anything I want?", "dlg_2_4")
  44. StartConversation(conversation, NPC, Spawn, "If you're close enough to your foe and want to start hitting it with your weapon, either click your Melee Attack button on your hotbar or press the ~ key. Or you can begin by using one of your spells or combat arts to get the enemy's attention. Remember, you must be close enough to actually hit them.")
  45. end
  46. function dlg_2_4(NPC, Spawn)
  47. FaceTarget(NPC, Spawn)
  48. conversation = CreateConversation()
  49. AddConversationOption(conversation, "Tell me about melee combat.", "dlg_2_5")
  50. AddConversationOption(conversation, "Tell me about ranged combat.", "dlg_2_7")
  51. AddConversationOption(conversation, "What kind of rewards can I earn in battle?", "dlg_2_14")
  52. AddConversationOption(conversation, "Teach me more advanced aspects of combat.", "dlg_2_17")
  53. AddConversationOption(conversation, "I'll come back later.")
  54. StartConversation(conversation, NPC, Spawn, "You can fight most non-player characters and creatures that you find outside your city, whether outdoors or in dungeons. Many non-player characters in the cities are there to help you or give quests, so you can't attack some of them. If you try, you'll get a message telling you that they aren't valid targets.")
  55. end
  56. function dlg_2_5(NPC, Spawn)
  57. FaceTarget(NPC, Spawn)
  58. conversation = CreateConversation()
  59. AddConversationOption(conversation, "What classes specialize in melee combat?", "dlg_2_6")
  60. StartConversation(conversation, NPC, Spawn, "Melee combat means a toe-to-toe, physical confrontation. It is a combination of auto-attack damage that happens automatically when you press the Melee Attack button on your hotbar or the ~ key and spells or combat arts that you use in close proximity to your foe.")
  61. end
  62. function dlg_2_6(NPC, Spawn)
  63. FaceTarget(NPC, Spawn)
  64. conversation = CreateConversation()
  65. AddConversationOption(conversation, "Tell me how to begin a fight.", "dlg_2_2")
  66. AddConversationOption(conversation, "Tell me about ranged combat.", "dlg_2_7")
  67. AddConversationOption(conversation, "What kind of rewards can I earn in battle?", "dlg_2_14")
  68. AddConversationOption(conversation, "Teach me more advanced aspects of combat.","dlg_2_17")
  69. AddConversationOption(conversation, "I'll come back later.")
  70. StartConversation(conversation, NPC, Spawn, "Sturdy fighters such as Guardians, Berserkers, Bruisers, and Shadowknights stand at the front lines of battle facing the enemy. Crafty scouts such as Brigands, Assassins, Troubadors, and Dirges generally stay close to their foes as well, but prefer to launch attacks from the back or side where they are less likely to be counterattacked.")
  71. end
  72. function dlg_2_7(NPC, Spawn)
  73. FaceTarget(NPC, Spawn)
  74. conversation = CreateConversation()
  75. AddConversationOption(conversation, "How do I launch a ranged attack?", "dlg_2_8")
  76. StartConversation(conversation, NPC, Spawn, "Ranged combat means that you put some distance between yourself and the enemy. This can be done with weapons such as bows or throwing daggers, or with spells and arts that can be cast from a distance.")
  77. end
  78. function dlg_2_8(NPC, Spawn)
  79. FaceTarget(NPC, Spawn)
  80. conversation = CreateConversation()
  81. AddConversationOption(conversation, "What classes specialize in ranged combat?", "dlg_2_9")
  82. StartConversation(conversation, NPC, Spawn, "If you have a ranged weapon and ammunition, you can initiate ranged combat by using the Ranged Attack button on the Abilities tab of your Knowledge Book. You can drag this key to your hotbar if you like. Remember, you must have a ranged weapon in the Ranged slot of your inventory window and the correct type of ammunition in the Ammo slot.")
  83. end
  84. function dlg_2_9(NPC, Spawn)
  85. FaceTarget(NPC, Spawn)
  86. conversation = CreateConversation()
  87. AddConversationOption(conversation, "How do I tell if I can use spells or arts from a distance?", "dlg_2_10")
  88. StartConversation(conversation, NPC, Spawn, "While most classes have the ability to attack from a distance, scout classes such as Brigands, Troubadors, Dirges, and Assassins specialize in ranged physical attacks. Mages, priests, and Shadowknights have spells that do damage to their foes from a distance.")
  89. end
  90. function dlg_2_10(NPC, Spawn)
  91. FaceTarget(NPC, Spawn)
  92. conversation = CreateConversation()
  93. AddConversationOption(conversation, "Tell me how to begin a fight.", "dlg_2_2")
  94. AddConversationOption(conversation, "Tell me about melee combat.", "dlg_2_5")
  95. AddConversationOption(conversation, "What kind of rewards can I earn in battle?", "dlg_2_14")
  96. AddConversationOption(conversation, "Teach me more advanced aspects of combat.", "dlg_2_17")
  97. AddConversationOption(conversation, "I'll come back later.")
  98. StartConversation(conversation, NPC, Spawn, "You can right-click on a spell or art's icon and select 'Examine' to see what its range of effect is. In addition, if you target something and the icon for one of your spells or arts turns a dark red, that means the opponent is out of range of that ability.")
  99. end
  100. function dlg_2_14(NPC, Spawn)
  101. FaceTarget(NPC, Spawn)
  102. conversation = CreateConversation()
  103. AddConversationOption(conversation, "What do you mean by 'a worthy opponent'?", "dlg_2_15")
  104. StartConversation(conversation, NPC, Spawn, "Victory in battle can be very rewarding. Successful combat against a worthy opponent awards you experience (XP) to help you advance your level, as well as the chance at coin, usable items, and other valuables.")
  105. end
  106. function dlg_2_15(NPC, Spawn)
  107. FaceTarget(NPC, Spawn)
  108. conversation = CreateConversation()
  109. AddConversationOption(conversation, "Are certain types of targets more rewarding than others?", "dlg_2_16")
  110. StartConversation(conversation, NPC, Spawn, "You don't earn rewards for defeating foes that are too far below your level. If your target has a grey name, it means it is very weak and won't provide any benefit for beating it.")
  111. end
  112. function dlg_2_16(NPC, Spawn)
  113. FaceTarget(NPC, Spawn)
  114. conversation = CreateConversation()
  115. PlayFlavor(NPC, "", "", "", 0, 0, Spawn)
  116. AddConversationOption(conversation, "Tell me how to begin a fight.", "dlg_2_17")
  117. AddConversationOption(conversation, "Tell me about melee combat.", "dlg_2_5")
  118. AddConversationOption(conversation, "Tell me about ranged combat.", "dlg_2_14")
  119. AddConversationOption(conversation, "Teach me more advanced aspects of combat.", "dlg_2_17")
  120. AddConversationOption(conversation, "I'll come back later.")
  121. StartConversation(conversation, NPC, Spawn, "The tougher a foe, the better its chances to provide a valuable reward. Though defeating enemies alone provides nice rewards, defeating heroic enemies that require a group is even more rewarding. The very best items come from banding together multiple groups to defeat epic opponents.")
  122. end
  123. function dlg_2_17(NPC, Spawn)
  124. FaceTarget(NPC, Spawn)
  125. conversation = CreateConversation()
  126. AddConversationOption(conversation, "Tell me about selecting the right opponent.", "dlg_2_18")
  127. AddConversationOption(conversation, "Teach me about knowing my surroundings.", "dlg_6_21")
  128. AddConversationOption(conversation, "Tell me about using my abilities.", "dlg_6_23")
  129. AddConversationOption(conversation, "Teach me the basics of combat.", "dlg_2_1")
  130. AddConversationOption(conversation, "I'll come back later.")
  131. StartConversation(conversation, NPC, Spawn, "There are many advanced combat techniques that you will learn over time. There's no substitute for experience, Zuzoo! I'd be happy to discuss a few of these advanced aspects, such as selecting the right opponent, knowing your surroundings, and using your abilities.")
  132. end
  133. function dlg_2_18(NPC, Spawn)
  134. FaceTarget(NPC, Spawn)
  135. conversation = CreateConversation()
  136. AddConversationOption(conversation, "How do I tell if an opponent is too weak or too strong for me?", "dlg_2_19")
  137. StartConversation(conversation, NPC, Spawn, "Picking the right fight is crucial to victory. A weak opponent won't provide worthwhile rewards, while an overly powerful foe will result in your defeat. You need to keep your resources in mind as well as choosing the right target.")
  138. end
  139. function dlg_2_19(NPC, Spawn)
  140. FaceTarget(NPC, Spawn)
  141. conversation = CreateConversation()
  142. AddConversationOption(conversation, "What resources should I be keeping an eye on?", "dlg_2_20")
  143. StartConversation(conversation, NPC, Spawn, "Targeting an opponent will show you detailed information on its overall potency. Generally speaking, you'll find the best results from fighting opponents with blue, white, or yellow names.")
  144. end
  145. function dlg_2_20(NPC, Spawn)
  146. FaceTarget(NPC, Spawn)
  147. conversation = CreateConversation()
  148. AddConversationOption(conversation, "Teach me about knowing my surroundings.", "dlg_6_21")
  149. AddConversationOption(conversation, "Tell me about using my abilities.", "dlg_6_23")
  150. AddConversationOption(conversation, "Teach me the basics of combat.", "dlg_2_1")
  151. AddConversationOption(conversation, "I'll come back later.")
  152. StartConversation(conversation, NPC, Spawn, "Starting a fight when you are low on health or power is a very bad idea. Your choice of targets also depends on whether you're alone or grouped with other players. Forming a group allows you to take on tougher and more rewarding challenges than you could face alone.")
  153. end
  154. function dlg_6_21(NPC, Spawn)
  155. FaceTarget(NPC, Spawn)
  156. conversation = CreateConversation()
  157. AddConversationOption(conversation, "Anything else I should watch out for?", "dlg_6_22")
  158. StartConversation(conversation, NPC, Spawn, "Keeping your surroundings in mind is crucial to victory. Fighting in areas with lots of aggressive creatures is a bad idea, because they won't hesitate to gang up on you.")
  159. end
  160. function dlg_6_22(NPC, Spawn)
  161. FaceTarget(NPC, Spawn)
  162. conversation = CreateConversation()
  163. PlayFlavor(NPC, "", "", "", 0, 0, Spawn)
  164. AddConversationOption(conversation, "Tell me about selecting the right opponent.", "dlg_2_18")
  165. AddConversationOption(conversation, "Tell me about using my abilities.", "dlg_6_23")
  166. AddConversationOption(conversation, "Teach me the basics of combat.", "dlg_2_1")
  167. AddConversationOption(conversation, "I'll come back later.")
  168. StartConversation(conversation, NPC, Spawn, "You should be aware of what's going on around you. Using your mouse wheel to scroll out into third person and holding down the left mouse button allows you to move the camera around your character. It's a good idea to do this when fighting in dangerous areas to make sure nothing sneaks up on you.")
  169. end
  170. function dlg_6_23(NPC, Spawn)
  171. FaceTarget(NPC, Spawn)
  172. conversation = CreateConversation()
  173. AddConversationOption(conversation, "What do you mean?", "dlg_6_24")
  174. StartConversation(conversation, NPC, Spawn, "Successful fighting isn't about turning on your auto-attack and walking away from battle. Your odds of victory are much better if you are well-prepared and are active during combat. You should use every spell or combat art that has a positive effect on your chances to win.")
  175. end
  176. function dlg_6_24(NPC, Spawn)
  177. FaceTarget(NPC, Spawn)
  178. conversation = CreateConversation()
  179. AddConversationOption(conversation, "What about during battle?", "dlg_6_25")
  180. StartConversation(conversation, NPC, Spawn, "Before you begin fighting, make sure you and your allies have activated all beneficial spells, also known as 'buffs,' so that you're operating at peak efficiency. Buffs can add health or power, increase your rate of regeneration, enhance your physical attributes, make you attack faster or do more damage, and more.")
  181. end
  182. function dlg_6_25(NPC, Spawn)
  183. FaceTarget(NPC, Spawn)
  184. conversation = CreateConversation()
  185. AddConversationOption(conversation, "What else should I know about spells and arts?", "dlg_6_26")
  186. StartConversation(conversation, NPC, Spawn, "Whether you're a front-lines melee type or someone attacking from a distance with weapons or spells, you should be using abilities that damage your foes effectively and efficiently. Right click on your spells and arts and select 'Examine' to see details on their effects.")
  187. end
  188. function dlg_6_26(NPC, Spawn)
  189. FaceTarget(NPC, Spawn)
  190. conversation = CreateConversation()
  191. AddConversationOption(conversation, "Tell me about selecting the right opponent.", "dlg_2_18")
  192. AddConversationOption(conversation, "Teach me about knowing my surroundings.", "dlg_6_21")
  193. AddConversationOption(conversation, "Teach me the basics of combat.", "dlg_2_1")
  194. AddConversationOption(conversation, "I'll come back later.")
  195. StartConversation(conversation, NPC, Spawn, "Using your highest-level versions of spells and arts will be more effective than using older versions. In addition, you should be upgrading your abilities to higher ranks to make them more effective. For more details on spells and combat arts, talk to Trainer Yasna V'Vath.")
  196. end