9
3

aGraystoneGuildbruiserDojoFair02.lua 3.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101
  1. --[[
  2. Script Name : SpawnScripts/qeynos_combined02/aGraystoneGuildbruiserDojoFair02.lua
  3. Script Author : Rylec
  4. Script Date : 2021.02.17 12:02:26
  5. Script Purpose :
  6. :
  7. --]]
  8. local count = 1110
  9. function spawn(NPC)
  10. -- local BarbarianMale = MakeRandomInt(1467,1471)
  11. SetModelType(NPC, "112") -- barbarian male
  12. SpawnSet(NPC, "soga_model_type", "112")
  13. SpawnSet(NPC, "chest_type", "5461")
  14. SpawnSet(NPC, "legs_type", "5462")
  15. Hair(NPC)
  16. Face(NPC)
  17. -- AddTimer(NPC, math.random(2000,5000), "EmoteLoop")
  18. end
  19. function Hair(NPC)
  20. local Type = GetModelType(NPC)
  21. local HairType = 0
  22. if Type == 132 or Type == 134 then
  23. HairType = MakeRandomInt(1121,1140)
  24. SpawnSet(NPC, "hair_type", HairType)
  25. elseif Type == 110 or Type == 112 or Type == 121 or Type == 122 then
  26. HairType = MakeRandomInt(1133,1140)
  27. SpawnSet(NPC, "hair_type", HairType)
  28. elseif Type == 109 then
  29. HairType = MakeRandomInt(1135,1140)
  30. SpawnSet(NPC, "hair_type", HairType)
  31. else
  32. HairType = MakeRandomInt(1136,1140)
  33. SpawnSet(NPC, "hair_type", HairType)
  34. end
  35. end
  36. function Face(NPC)
  37. count = count + 1
  38. Say(NPC, "Count "..count.."")
  39. -- local Type = GetModelType(NPC)
  40. -- local FaceHairType = 0
  41. -- if Type == 134 then
  42. -- local FaceHairType = MakeRandomInt(1164,1191)
  43. SpawnSet(NPC, "facial_hair_type", count)
  44. -- elseif Type == 110 then
  45. -- local FaceHairType = MakeRandomInt(1164,1170)
  46. -- SpawnSet(NPC, "facial_hair_type", FaceHairType)
  47. -- else
  48. -- local FaceHairType = MakeRandomInt(1166,1175)
  49. -- SpawnSet(NPC, "facial_hair_type", FaceHairType)
  50. -- end
  51. AddTimer(NPC, 2000, "Face")
  52. end
  53. function hailed(NPC, Spawn)
  54. FaceTarget(NPC, Spawn)
  55. local type = GetModelType(NPC)
  56. local voice = MakeRandomInt(1,3)
  57. local spawnvoice = 0
  58. if type == 132 then
  59. spawnvoice = 1011
  60. elseif type == 134 then
  61. spawnvoice = 1054
  62. elseif type >= 91 and type <= 96 then
  63. spawnvoice = 1047
  64. elseif type >= 97 and type <= 102 then
  65. spawnvoice = 1048
  66. elseif type == 109 then
  67. spawnvoice = 1059
  68. elseif type == 110 then
  69. spawnvoice = 1004
  70. elseif type == 122 then
  71. spawnvoice = 1023
  72. elseif type == 121 then
  73. spawnvoice = 1024
  74. elseif type == 111 then
  75. spawnvoice = 1003
  76. elseif type == 112 then
  77. spawnvoice = 1004
  78. end
  79. PlayFlavor(NPC, "voiceover/english/voice_emotes/greetings/greetings_"..voice.."_"..spawnvoice..".mp3", "", "hello", 0, 0, Spawn)
  80. end
  81. function respawn(NPC)
  82. spawn(NPC)
  83. end
  84. function EmoteLoop(NPC)
  85. PlayAnimation(NPC, 11150)
  86. AddTimer(NPC, math.random(10000,15000), "EmoteLoop")
  87. end