night_master.lua 3.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196
  1. mobs:register_mob("nssm:night_master", {
  2. type = "monster",
  3. hp_max = 60,
  4. hp_min = 60,
  5. collisionbox = {-0.65, -0.4, -0.65, 0.65, 0.4, 0.65},
  6. visual = "mesh",
  7. mesh = "moonherontrio.x",
  8. textures = {
  9. {"moonherontrio.png"}
  10. },
  11. visual_size = {x = 18, y = 18},
  12. view_range = 40,
  13. rotate = 270,
  14. lifetimer = 500,
  15. floats=1,
  16. walk_velocity = 3,
  17. run_velocity = 4,
  18. fall_speed = 0,
  19. stepheight = 3,
  20. sounds = {
  21. random = "night_master",
  22. distance = 45,
  23. },
  24. damage = 10,
  25. jump = false,
  26. armor = 60,
  27. drawtype = "front",
  28. water_damage = 0,
  29. lava_damage = 5,
  30. fire_damage = 5,
  31. light_damage = 0,
  32. blood_texture = "nssm_blood.png",
  33. blood_amount = 50,
  34. fly = true,
  35. attack_type = "dogfight",
  36. animation = {
  37. speed_normal = 25,
  38. speed_run = 35,
  39. stand_start = 60,
  40. stand_end = 120,
  41. walk_start = 20,
  42. walk_end = 50,
  43. run_start = 20,
  44. run_end = 50,
  45. punch_start = 130,
  46. punch_end = 160,
  47. },
  48. on_die = function(self, pos)
  49. minetest.add_particlespawner({
  50. amount = 200,
  51. time = 0.1,
  52. minpos = {x=pos.x-1, y=pos.y-1, z=pos.z-1},
  53. maxpos = {x=pos.x+1, y=pos.y+1, z=pos.z+1},
  54. minvel = {x=-0, y=-0, z=-0},
  55. maxvel = {x=1, y=1, z=1},
  56. minacc = {x=-0.5,y=5,z=-0.5},
  57. maxacc = {x=0.5,y=5,z=0.5},
  58. minexptime = 0.1,
  59. maxexptime = 1,
  60. minsize = 3,
  61. maxsize = 4,
  62. collisiondetection = false,
  63. texture = "tnt_smoke.png"
  64. })
  65. self.object:remove()
  66. minetest.add_entity(pos, "nssm:night_master_2")
  67. end,
  68. })
  69. mobs:register_mob("nssm:night_master_2", {
  70. type = "monster",
  71. hp_max = 60,
  72. hp_min = 60,
  73. collisionbox = {-0.65, -0.4, -0.65, 0.65, 0.4, 0.65},
  74. visual = "mesh",
  75. mesh = "night_master_2.x",
  76. textures = {
  77. {"moonherontrio.png"}
  78. },
  79. visual_size = {x = 18, y = 18},
  80. view_range = 40,
  81. rotate = 270,
  82. lifetimer = 500,
  83. floats = 1,
  84. walk_velocity = 3,
  85. run_velocity = 4,
  86. fall_speed = 0,
  87. stepheight = 3,
  88. sounds = {
  89. random = "night_master",
  90. distance = 45,
  91. },
  92. damage = 10,
  93. jump = false,
  94. armor = 60,
  95. drawtype = "front",
  96. water_damage = 0,
  97. lava_damage = 5,
  98. fire_damage = 5,
  99. light_damage = 0,
  100. fly = true,
  101. attack_type = "dogfight",
  102. animation = {
  103. speed_normal = 25,
  104. speed_run = 35,
  105. stand_start = 60,
  106. stand_end = 120,
  107. walk_start = 20,
  108. walk_end = 50,
  109. run_start = 20,
  110. run_end = 50,
  111. punch_start = 130,
  112. punch_end = 160,
  113. },
  114. on_die = function(self, pos)
  115. minetest.add_particlespawner({
  116. amount = 200,
  117. time = 0.1,
  118. minpos = {x=pos.x-1, y=pos.y-1, z=pos.z-1},
  119. maxpos = {x=pos.x+1, y=pos.y+1, z=pos.z+1},
  120. minvel = {x=-0, y=-0, z=-0},
  121. maxvel = {x=1, y=1, z=1},
  122. minacc = {x=-0.5,y=5,z=-0.5},
  123. maxacc = {x=0.5,y=5,z=0.5},
  124. minexptime = 0.1,
  125. maxexptime = 1,
  126. minsize = 3,
  127. maxsize = 4,
  128. collisiondetection = false,
  129. texture = "tnt_smoke.png"
  130. })
  131. self.object:remove()
  132. minetest.add_entity(pos, "nssm:night_master_1")
  133. end,
  134. })
  135. mobs:register_mob("nssm:night_master_1", {
  136. type = "monster",
  137. hp_max = 70,
  138. hp_min = 70,
  139. collisionbox = {-0.65, -0.4, -0.65, 0.65, 0.4, 0.65},
  140. visual = "mesh",
  141. mesh = "night_master_1.x",
  142. textures = {
  143. {"moonherontrio.png"}
  144. },
  145. visual_size = {x = 18, y = 18},
  146. view_range = 40,
  147. rotate = 270,
  148. lifetimer = 500,
  149. floats=1,
  150. walk_velocity = 3,
  151. run_velocity = 4,
  152. fall_speed = 0,
  153. stepheight = 3,
  154. sounds = {
  155. random = "night_master",
  156. distance = 45,
  157. },
  158. damage = 12,
  159. jump = false,
  160. drops = {
  161. {name = "nssm:life_energy", chance = 1, min = 6, max = 7},
  162. {name = "nssm:heron_leg", chance = 1, min = 1, max = 1},
  163. {name = "nssm:night_feather", chance = 1, min = 1, max = 1},
  164. },
  165. armor = 50,
  166. drawtype = "front",
  167. water_damage = 0,
  168. lava_damage = 5,
  169. fire_damage = 5,
  170. light_damage = 0,
  171. fly = true,
  172. attack_type = "dogfight",
  173. animation = {
  174. speed_normal = 25,
  175. speed_run = 35,
  176. stand_start = 60,
  177. stand_end = 120,
  178. walk_start = 20,
  179. walk_end = 50,
  180. run_start = 20,
  181. run_end = 50,
  182. punch_start = 130,
  183. punch_end = 160,
  184. }
  185. })