woodrow.lua 5.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160
  1. --[[
  2. Script Name : woodrow.lua
  3. Script Purpose : Waypoint Path for woodrow.lua
  4. Script Author : Devn00b
  5. Script Date : 04/11/2020 06:13:14 PM
  6. Script Notes : Locations collected from Live
  7. --]]
  8. dofile("SpawnScripts/Generic/GenericGuardVoiceOvers.lua")
  9. function spawn(NPC)
  10. SetPlayerProximityFunction(NPC, 10, "InRange", "LeaveRange")
  11. --waypoints(NPC)
  12. end
  13. function respawn(NPC)
  14. spawn(NPC)
  15. end
  16. function InRange(NPC, Spawn)
  17. if GetFactionAmount(Spawn,11) >20000 then
  18. if math.random(0, 100) <= 25 then
  19. FaceTarget(NPC, Spawn)
  20. PlayFlavor(NPC, "voiceover/english/barbarian_eco_good_1/ft/service/guard/barbarian_guard_service_good_1_hail_gm_ee473c11.mp3", "Good day to you, citizen. All preserve Queen Antonia.", "salute", 2268064933, 2349331472, Spawn)
  21. else
  22. CheckFaction(NPC, Spawn, "Qeynos")
  23. end
  24. end
  25. end
  26. function hailed(NPC, Spawn)
  27. FaceTarget(NPC, Spawn)
  28. GenericGuardHail(NPC, Spawn)
  29. end
  30. function waypoints(NPC)
  31. MovementLoopAddLocation(NPC, 673.7, -21.14, 144.6, 2, 0)
  32. MovementLoopAddLocation(NPC, 682.32, -20.67, 157.2, 2, 0)
  33. MovementLoopAddLocation(NPC, 721.58, -19.64, 183.31, 2, 0)
  34. MovementLoopAddLocation(NPC, 724.37, -19.88, 185.32, 2, 0)
  35. MovementLoopAddLocation(NPC, 778.22, -21.01, 178.06, 2, 1)
  36. MovementLoopAddLocation(NPC, 778.22, -21.01, 178.06, 2, 8,"FaceGuard2")
  37. MovementLoopAddLocation(NPC, 778.22, -21.01, 178.06, 2, 1)
  38. MovementLoopAddLocation(NPC, 743.16, -20.65, 189.88, 2, 0)
  39. MovementLoopAddLocation(NPC, 744.9, -19.02, 198.56, 2, 0)
  40. MovementLoopAddLocation(NPC, 739.77, -20.59, 189.28, 2, 0)
  41. MovementLoopAddLocation(NPC, 721.95, -19.32, 203.18, 2, 0)
  42. MovementLoopAddLocation(NPC, 720.31, -19.56, 194.64, 2, 0)
  43. MovementLoopAddLocation(NPC, 707.27, -19.53, 196.34, 2, 0)
  44. MovementLoopAddLocation(NPC, 702.15, -19.49, 176.73, 2, 0)
  45. MovementLoopAddLocation(NPC, 675.8, -20.59, 157.81, 2, 0)
  46. MovementLoopAddLocation(NPC, 668.62, -21.19, 145.22, 2, 0)
  47. MovementLoopAddLocation(NPC, 666.2, -21.3, 132.47, 2, 0)
  48. MovementLoopAddLocation(NPC, 663.46, -21.16, 105.58, 2, 0)
  49. MovementLoopAddLocation(NPC, 654.3, -20.75, 102.88, 2, 0)
  50. MovementLoopAddLocation(NPC, 643.14, -20.66, 97.19, 2, 0)
  51. MovementLoopAddLocation(NPC, 626.94, -26.4, 103.99, 2, 1)
  52. MovementLoopAddLocation(NPC, 626.94, -26.4, 103.99, 2, 8,"FaceGuard")
  53. MovementLoopAddLocation(NPC, 626.94, -26.4, 103.99, 2, 1)
  54. MovementLoopAddLocation(NPC, 643.14, -20.66, 97.19, 2, 0)
  55. MovementLoopAddLocation(NPC, 654.3, -20.75, 102.88, 2, 0)
  56. MovementLoopAddLocation(NPC, 663.46, -21.16, 105.58, 2, 0)
  57. MovementLoopAddLocation(NPC, 666.2, -21.3, 132.47, 2, 0)
  58. MovementLoopAddLocation(NPC, 668.62, -21.19, 145.22, 2, 0)
  59. MovementLoopAddLocation(NPC, 675.8, -20.59, 157.81, 2, 0)
  60. MovementLoopAddLocation(NPC, 702.15, -19.49, 176.73, 2, 0)
  61. MovementLoopAddLocation(NPC, 707.27, -19.53, 196.34, 2, 0)
  62. MovementLoopAddLocation(NPC, 720.31, -19.56, 194.64, 2, 0)
  63. MovementLoopAddLocation(NPC, 721.95, -19.32, 203.18, 2, 0)
  64. MovementLoopAddLocation(NPC, 739.77, -20.59, 189.28, 2, 0)
  65. MovementLoopAddLocation(NPC, 744.9, -19.02, 198.56, 2, 0)
  66. MovementLoopAddLocation(NPC, 743.16, -20.65, 189.88, 2, 0)
  67. MovementLoopAddLocation(NPC, 778.22, -21.01, 178.06, 2, 0)
  68. MovementLoopAddLocation(NPC, 724.37, -19.88, 185.32, 2, 0)
  69. MovementLoopAddLocation(NPC, 721.58, -19.64, 183.31, 2, 0)
  70. MovementLoopAddLocation(NPC, 682.32, -20.67, 157.2, 2, 0)
  71. MovementLoopAddLocation(NPC, 673.7, -21.14, 144.6, 2, 0)
  72. end
  73. function FaceGuard(NPC) -- Saluting script
  74. local Krelal = GetSpawn(NPC, 2310078)
  75. if Krelal ~= nil then
  76. FaceTarget(NPC, Krelal)
  77. AddTimer(NPC, 1000, "CaptainFacesGuard")
  78. end
  79. end
  80. function CaptainFacesGuard(NPC)
  81. local Krelal = GetSpawn(NPC, 2310078)
  82. if Krelal ~= nil then
  83. FaceTarget(Krelal, NPC)
  84. AddTimer(NPC, 500, "CaptainSalutesGuard")
  85. end
  86. end
  87. function CaptainSalutesGuard(NPC)
  88. local Krelal = GetSpawn(NPC, 2310078)
  89. if Krelal ~= nil then
  90. PlayAnimation(Krelal, 12167)
  91. AddTimer(NPC, 1000, "SaluteCaptain")
  92. end
  93. end
  94. function SaluteCaptain(NPC)
  95. local Krelal = GetSpawn(NPC, 2310078)
  96. if Krelal ~= nil then
  97. PlayAnimation(NPC, 12167)
  98. -- AddTimer(NPC, 1000, "CaptainFacesGuard")
  99. end
  100. end
  101. -----------------------------------------------------------
  102. function FaceGuard2(NPC) -- Saluting script
  103. local Mott = GetSpawn(NPC, 2310119)
  104. if Mott ~= nil then
  105. FaceTarget(NPC, Mott)
  106. AddTimer(NPC, 1000, "CaptainFacesGuard2")
  107. end
  108. end
  109. function CaptainFacesGuard2(NPC)
  110. local Mott = GetSpawn(NPC, 2310119)
  111. if Mott ~= nil then
  112. FaceTarget(Mott, NPC)
  113. AddTimer(NPC, 500, "CaptainSalutesGuard2")
  114. end
  115. end
  116. function CaptainSalutesGuard2(NPC)
  117. local Mott = GetSpawn(NPC, 2310119)
  118. if Mott ~= nil then
  119. PlayAnimation(Mott, 12167)
  120. AddTimer(NPC, 1000, "SaluteCaptain2")
  121. end
  122. end
  123. function SaluteCaptain2(NPC)
  124. local Mott = GetSpawn(NPC, 2310119)
  125. if Mott ~= nil then
  126. PlayAnimation(NPC, 12167)
  127. -- AddTimer(NPC, 1000, "CaptainFacesGuard2")
  128. end
  129. end