9
3

WarbleWildmane.lua 2.3 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980
  1. --[[
  2. Script Name : SpawnScripts/qeynos_combined02/WarbleWildmane.lua
  3. Script Author : Rylec
  4. Script Date : 2021.07.29 01:07:06
  5. Script Purpose :
  6. :
  7. --]]
  8. function spawn(NPC)
  9. waypoints(NPC)
  10. end
  11. function hailed(NPC, Spawn)
  12. FaceTarget(NPC, Spawn)
  13. local voice = MakeRandomInt(1,3)
  14. PlayFlavor(NPC, "voiceover/english/voice_emotes/greetings/greetings_"..voice.."_1026.mp3", "", "", 0, 0, Spawn)
  15. conversation = CreateConversation()
  16. AddConversationOption(conversation, "Sorry to interrupt. Goodbye.", "conv_01")
  17. StartConversation(conversation, NPC, Spawn, "Shh! Old Treebark's talking!")
  18. end
  19. function conv_01(NPC, Spawn)
  20. FaceTarget(NPC, Spawn)
  21. conversation = CreateConversation()
  22. AddConversationOption(conversation, "Goodbye.")
  23. StartConversation(conversation, NPC, Spawn, "Goodbye!")
  24. end
  25. function waypoints(NPC)
  26. MoveToLocation(NPC, 744.19, -16.16, -300.48, 3.5)
  27. AddTimer(NPC, math.random(20000,40000), "corner_A_01")
  28. end
  29. function corner_A_01(NPC)
  30. MoveToLocation(NPC, 753.28, -16.23, -297.81, 3.5)
  31. AddTimer(NPC, math.random(20000,60000), "between_corner_A_and_B")
  32. end
  33. function between_corner_A_and_B(NPC)
  34. MoveToLocation(NPC, 751.92, -16.17, -296.89, 3.5)
  35. AddTimer(NPC, math.random(20000,40000), "corner_A_02")
  36. end
  37. function corner_A_02(NPC)
  38. MoveToLocation(NPC, 753.28, -16.23, -297.81, 3.5)
  39. AddTimer(NPC, math.random(20000,60000), "corner_B_01")
  40. end
  41. function corner_B_01(NPC)
  42. MoveToLocation(NPC, 743.9, -16.64, -291.35, 3.5)
  43. AddTimer(NPC, math.random(20000,50000), "between_corner_B_and_C")
  44. end
  45. function between_corner_B_and_C(NPC)
  46. MoveToLocation(NPC, 742.24, -16.43, -297.07, 3.5)
  47. AddTimer(NPC, math.random(20000,40000), "corner_B_02")
  48. end
  49. function corner_B_02(NPC)
  50. MoveToLocation(NPC, 743.74, -16.56, -292.45, 3.5)
  51. AddTimer(NPC, math.random(20000,50000), "corner_C_01")
  52. end
  53. function corner_C_01(NPC)
  54. MoveToLocation(NPC, 740.36, -16.39, -300.84, 3.5)
  55. AddTimer(NPC, math.random(20000,60000), "corner_A_03")
  56. end
  57. function corner_A_03(NPC)
  58. MoveToLocation(NPC, 751.97, -16.15, -299.14, 3.5)
  59. AddTimer(NPC, math.random(20000,50000), "waypoints")
  60. end
  61. function respawn(NPC)
  62. spawn(NPC)
  63. end