nssm/mobs/sandworm.lua

59 lines
1.2 KiB
Lua
Raw Normal View History

2018-08-08 12:56:14 +03:00
mobs:register_mob("nssm:sandworm", {
type = "monster",
hp_max = 40,
hp_min = 25,
collisionbox = {-0.4, -0.2, -0.4, 0.4, 1.90, 0.4},
visual = "mesh",
mesh = "sandworm.x",
textures = {
{"sandworm.png"}
},
visual_size = {x = 4, y = 4},
2018-08-08 12:56:14 +03:00
makes_footstep_sound = false,
view_range = 17,
rotate = 270,
reach = 2,
fear_height = 3,
walk_velocity = 2,
run_velocity = 2,
damage = 6,
sounds = {
random = "sandworm",
2022-09-28 12:41:38 +03:00
distance = 40
2018-08-08 12:56:14 +03:00
},
jump = false,
drops = {
{name = "nssm:worm_flesh", chance = 2, min = 1, max = 3},
{name = "nssm:sandworm_skin", chance = 2, min = 1, max = 3},
2022-09-28 12:41:38 +03:00
{name = "nssm:life_energy", chance = 1, min = 2, max = 3}
2018-08-08 12:56:14 +03:00
},
armor = 60,
drawtype = "front",
water_damage = 5,
lava_damage = 10,
2021-04-05 11:49:24 +03:00
fire_damage = 10,
2018-08-08 12:56:14 +03:00
light_damage = 0,
group_attack = true,
attack_animals = true,
knock_back = 2,
blood_texture = "nssm_blood_blue.png",
stepheight = 1.1,
2018-08-08 12:56:14 +03:00
attack_type = "dogfight",
animation = {
speed_normal = 25,
speed_run = 40,
stand_start = 1,
stand_end = 100,
walk_start = 110,
walk_end = 140,
run_start = 110,
run_end = 140,
punch_start = 150,
2022-09-28 12:41:38 +03:00
punch_end = 180
2018-08-08 12:56:14 +03:00
},
2022-09-28 21:01:53 +03:00
2018-08-08 12:56:14 +03:00
do_custom = function(self)
digging_attack(self, "sand", self.run_velocity, {x = 0, y = 3, z = 0})
2022-09-28 12:41:38 +03:00
end
2018-08-08 12:56:14 +03:00
})