9
3

GrayMagnificent.lua 2.0 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374
  1. --[[
  2. Script Name : SpawnScripts/NorthQeynos/GrayMagnificent.lua
  3. Script Author : Dorbin
  4. Script Date : 2022.05.13 02:05:32
  5. Script Purpose :
  6. :
  7. --]]
  8. function spawn(NPC)
  9. AddTimer(NPC, 5000, "EmoteLoop")
  10. AddTimer(NPC, 12000,"Swooning")
  11. end
  12. function hailed(NPC, Spawn)
  13. end
  14. function respawn(NPC)
  15. spawn(NPC)
  16. end
  17. function EmoteLoop(NPC)
  18. local emoteChoice = MakeRandomInt(1,4)
  19. if emoteChoice == 1 then
  20. -- flourish
  21. PlayAnimation(NPC, 298)
  22. AddTimer(NPC, MakeRandomInt(10000,12000), "EmoteLoop")
  23. elseif emoteChoice == 2 then
  24. -- kiss
  25. PlayAnimation(NPC, 11762)
  26. AddTimer(NPC, MakeRandomInt(5000,8000), "EmoteLoop")
  27. elseif emoteChoice == 3 then
  28. -- dance
  29. PlayAnimation(NPC, 11298)
  30. AddTimer(NPC, MakeRandomInt(10000,12000), "EmoteLoop")
  31. elseif emoteChoice == 4 then
  32. -- full curtsey
  33. PlayAnimation(NPC, 11633)
  34. AddTimer(NPC, MakeRandomInt(7000,9000), "EmoteLoop")
  35. end
  36. end
  37. function Swooning(NPC,Spawn)
  38. local Laura = GetSpawn(NPC, 2220056)
  39. local Lilly = GetSpawn(NPC, 2220115)
  40. if Laura ~= nil then
  41. FaceTarget(Laura,NPC)
  42. SetTarget(Laura,NPC)
  43. choice = math.random(1,3)
  44. if choice == 1 then
  45. PlayFlavor(Laura, "","", "flustered", 0, 0)
  46. elseif choice == 2 then
  47. PlayFlavor(Laura, "","", "cheer", 0, 0)
  48. elseif choice == 2 then
  49. PlayFlavor(Laura, "","", "snicker", 0, 0)
  50. end
  51. end
  52. if Lilly ~=nil then
  53. FaceTarget(Lilly,NPC)
  54. SetTarget(Lilly,NPC)
  55. choice = math.random(1,3)
  56. if choice == 1 then
  57. PlayFlavor(Lilly, "","", "happy", 0, 0)
  58. elseif choice == 2 then
  59. PlayFlavor(Lilly, "","", "giggle", 0, 0)
  60. elseif choice == 3 then
  61. PlayFlavor(Lilly, "","", "nod", 0, 0)
  62. end
  63. end
  64. AddTimer(NPC, MakeRandomInt(25000,32000), "Swooning")
  65. end