121 lines
2.9 KiB
Lua
121 lines
2.9 KiB
Lua
minetest.register_craft({
|
|
type = "cooking",
|
|
output = "mobs:meat",
|
|
recipe = "mobs_dolphin:dolphin_set",
|
|
})
|
|
|
|
if mobs.mod and mobs.mod == "redo" then
|
|
|
|
local l_water_level = minetest.setting_get("water_level") - 1
|
|
|
|
-- Normal dolphin
|
|
|
|
mobs:register_mob("mobs_dolphin:dolphin", {
|
|
type = "monster",
|
|
passive = false,
|
|
attack_type = "dogfight",
|
|
pathfinding = true,
|
|
reach = 3,
|
|
damage = 4,
|
|
hp_min = 30,
|
|
hp_max = 40,
|
|
armor = 150,
|
|
collisionbox = {-0.75, -0.5, -0.75, 0.75, 0.5, 0.75},
|
|
visual = "mesh",
|
|
mesh = "mobs_dolphin.b3d",
|
|
textures = {
|
|
{"dolphin_blue.png"},
|
|
{"dolphin_white.png"}
|
|
},
|
|
sounds = {
|
|
random = "dolphin",
|
|
},
|
|
drops = {
|
|
{name = "mobs:meat_raw", chance = 1, min = 1, max = 1},
|
|
},
|
|
makes_footstep_sound = false,
|
|
walk_velocity = 3,
|
|
run_velocity = 4,
|
|
fly = true,
|
|
fly_in = "default:water_source",
|
|
fall_speed = 0,
|
|
rotate = 0,
|
|
view_range = 10,
|
|
water_damage = 0,
|
|
lava_damage = 10,
|
|
light_damage = 0,
|
|
animation = {
|
|
speed_normal = 15,
|
|
speed_run = 15,
|
|
stand_start = 66,
|
|
stand_end = 90,
|
|
walk_start = 0,
|
|
walk_end = 40,
|
|
run_start = 40,
|
|
run_end = 60,
|
|
punch_start = 40,
|
|
punch_end = 40,
|
|
},
|
|
follow = {"ethereal:fish_raw"},
|
|
on_rightclick = function(self, clicker)
|
|
mobs:capture_mob(self, clicker, 80, 100, 0, true, nil)
|
|
end
|
|
})
|
|
--name, nodes, neighbours, minlight, maxlight, interval, chance, active_object_count, min_height, max_height
|
|
mobs:spawn_specific("mobs_dolphin:dolphin", {"default:water_source"}, {"default:water_flowing","default:water_source"}, 5, 20, 30, 100000, 2, -100, l_water_level)
|
|
mobs:register_egg("mobs_dolphin:dolphin", "Dolphin", "dolphin_inv.png", 0)
|
|
|
|
-- Robot dolphin
|
|
|
|
mobs:register_mob("mobs_dolphin:robot_dolphin", {
|
|
type = "monster",
|
|
passive = false,
|
|
attack_type = "dogfight",
|
|
pathfinding = true,
|
|
reach = 3,
|
|
damage = 8,
|
|
hp_min = 100,
|
|
hp_max = 200,
|
|
armor = 300,
|
|
collisionbox = {-0.75, -0.5, -0.75, 0.75, 0.5, 0.75},
|
|
visual = "mesh",
|
|
mesh = "mobs_dolphin.b3d",
|
|
textures = {
|
|
{"robot_dolphin.png"}
|
|
},
|
|
sounds = {
|
|
random = "robot_dolphin"
|
|
},
|
|
drops = {
|
|
{name = "default:mese_crystal_fragment", chance = 1, min = 1, max = 3}
|
|
},
|
|
makes_footstep_sound = false,
|
|
walk_velocity = 2,
|
|
run_velocity = 12,
|
|
fly = true,
|
|
fly_in = "default:water_source",
|
|
fall_speed = 0,
|
|
rotate = 0,
|
|
view_range = 12,
|
|
water_damage = 0,
|
|
lava_damage = 0,
|
|
light_damage = 0,
|
|
animation = {
|
|
speed_normal = 15,
|
|
speed_run = 15,
|
|
stand_start = 66,
|
|
stand_end = 90,
|
|
walk_start = 0,
|
|
walk_end = 40,
|
|
run_start = 40,
|
|
run_end = 60,
|
|
punch_start = 40,
|
|
punch_end = 40,
|
|
}
|
|
|
|
})
|
|
--name, nodes, neighbours, minlight, maxlight, interval, chance, active_object_count, min_height, max_height
|
|
mobs:spawn_specific("mobs_dolphin:robot_dolphin", {"default:water_source"}, {"default:water_flowing","default:water_source"}, 0, 15, 30, 10000, 2, -1000, -100)
|
|
|
|
end
|