Rhast.lua 2.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475
  1. --[[
  2. Script Name : SpawnScripts/TempleSt/Rhast.lua
  3. Script Author : Dorbin
  4. Script Date : 2023.10.28 04:10:58
  5. Script Purpose :
  6. :
  7. --]]
  8. dofile("SpawnScripts/Generic/GenericEcologyVoiceOvers.lua")
  9. function spawn(NPC)
  10. SetPlayerProximityFunction(NPC, 6, "InRange", "LeaveRange")
  11. waypoints(NPC)
  12. end
  13. function hailed(NPC, Spawn)
  14. FaceTarget(NPC, Spawn)
  15. GenericEcologyHail(NPC, Spawn, faction)
  16. end
  17. function InRange(NPC,Spawn)
  18. GenericEcologyCallout(NPC, Spawn, faction)
  19. end
  20. function respawn(NPC)
  21. spawn(NPC)
  22. end
  23. function waypoints(NPC)
  24. MovementLoopAddLocation(NPC, 93.23, -4.57, 100.4, 2, 1)
  25. MovementLoopAddLocation(NPC, 93.23, -4.57, 100.4, 2, 30,"Drink")
  26. MovementLoopAddLocation(NPC, 93.23, -4.57, 100.4, 2, 30,"Drink")
  27. MovementLoopAddLocation(NPC, 93.23, -4.57, 100.4, 2, 0)
  28. MovementLoopAddLocation(NPC, 94.22, -4.57, 101.35, 2, 0)
  29. MovementLoopAddLocation(NPC, 92.92, -4.57, 102.22, 2, 0)
  30. MovementLoopAddLocation(NPC, 86.16, -4.57, 103.94, 2, 0)
  31. MovementLoopAddLocation(NPC, 83.65, -4.57, 109.76, 2, 0)
  32. MovementLoopAddLocation(NPC, 81.93, -4.57, 112.9, 2, 0)
  33. MovementLoopAddLocation(NPC, 78.67, -4.57, 115, 2, 1)
  34. MovementLoopAddLocation(NPC, 78.67, -4.57, 115, 2, 20,"EcologyEmotes")
  35. MovementLoopAddLocation(NPC, 81.34, -4.57, 113.59, 2, 0)
  36. MovementLoopAddLocation(NPC, 80.99, -4.57, 111.82, 2, 1)
  37. MovementLoopAddLocation(NPC, 80.99, -4.57, 111.82, 2, 20,"EcologyEmotes")
  38. MovementLoopAddLocation(NPC, 80.99, -4.57, 111.82, 2, 0)
  39. MovementLoopAddLocation(NPC, 82.59, -4.57, 111.99, 2, 0)
  40. MovementLoopAddLocation(NPC, 83.83, -4.57, 110.25, 2, 0)
  41. MovementLoopAddLocation(NPC, 88.09, -4.57, 104.42, 2, 0)
  42. MovementLoopAddLocation(NPC, 97.45, -4.57, 101.72, 2, 0)
  43. MovementLoopAddLocation(NPC, 101.39, -4.57, 100.11, 2, 0)
  44. MovementLoopAddLocation(NPC, 101.39, -4.57, 100.11, 2, 1)
  45. MovementLoopAddLocation(NPC, 101.39, -4.57, 100.11, 2, 30,"Drink")
  46. MovementLoopAddLocation(NPC, 101.04, -4.57, 100.48, 2, 0)
  47. MovementLoopAddLocation(NPC, 99.76, -4.57, 100.93, 2, 0)
  48. MovementLoopAddLocation(NPC, 95.38, -4.57, 102.42, 2, 0)
  49. end
  50. function Drink(NPC)
  51. PlayFlavor(NPC,"","","drinking_idle",0,0)
  52. AddTimer(NPC,8000, "Drink2")
  53. end
  54. function Drink2(NPC)
  55. choice = math.random(1,2)
  56. if choice == 1 then
  57. PlayFlavor(NPC,"","","yawn",0,0)
  58. else
  59. PlayFlavor(NPC,"","","happy",0,0)
  60. end
  61. AddTimer(NPC,6000, "Drink3")
  62. end
  63. function Drink3(NPC)
  64. PlayFlavor(NPC,"","","drinking_idle",0,0)
  65. end