diff --git a/README.md b/README.md index ca6cea3..4b77819 100644 --- a/README.md +++ b/README.md @@ -1,4 +1,6 @@ A few water critters ported from other mob frameworks to "Mobs-Redo". +Depends on Mobs Redo API - https://notabug.org/TenPlus1/mobs_redo + License information for the models and textures can be found inside the respective folders. diff --git a/mobs_crocs/init.lua b/mobs_crocs/init.lua index d6ce5f6..e7ec222 100644 --- a/mobs_crocs/init.lua +++ b/mobs_crocs/init.lua @@ -54,7 +54,11 @@ if mobs.mod and mobs.mod == "redo" then water_damage = 0, lava_damage = 10, light_damage = 0, - animation = l_anims + animation = l_anims, + drops = { + {name = "mobs:meat_raw", chance = 1, min = 1, max = 3}, + {name = "mobs:leather", chance = 1, min = 0, max = 2}, + }, }) --name, nodes, neighbours, minlight, maxlight, interval, chance, active_object_count, min_height, max_height mobs:spawn_specific("mobs_crocs:crocodile", @@ -87,7 +91,11 @@ if mobs.mod and mobs.mod == "redo" then water_damage = 0, lava_damage = 10, light_damage = 0, - animation = l_anims + animation = l_anims, + drops = { + {name = "mobs:meat_raw", chance = 1, min = 1, max = 3}, + {name = "mobs:leather", chance = 1, min = 0, max = 2}, + }, }) --name, nodes, neighbours, minlight, maxlight, interval, chance, active_object_count, min_height, max_height mobs:spawn_specific("mobs_crocs:crocodile_float", @@ -122,7 +130,11 @@ if mobs.mod and mobs.mod == "redo" then water_damage = 0, lava_damage = 10, light_damage = 0, - animation = l_anims + animation = l_anims, + drops = { + {name = "mobs:meat_raw", chance = 1, min = 1, max = 3}, + {name = "mobs:leather", chance = 1, min = 0, max = 2}, + }, }) --name, nodes, neighbours, minlight, maxlight, interval, chance, active_object_count, min_height, max_height mobs:spawn_specific("mobs_crocs:crocodile_swim", diff --git a/mobs_fish/init.lua b/mobs_fish/init.lua index e48ad45..d5fa1eb 100644 --- a/mobs_fish/init.lua +++ b/mobs_fish/init.lua @@ -9,7 +9,7 @@ local SPRITE_VERSION = false -- set to true to use upright sprites instead of me local l_spawn_chance = 10000 local l_cc_hand = 25 local l_cc_net = 80 - local l_water_level = minetest.setting_get("water_level") - 1 + local l_water_level = minetest.settings:get("water_level") - 1 local l_anims = { speed_normal = 24, speed_run = 24, stand_start = 1, stand_end = 80, @@ -19,7 +19,7 @@ local SPRITE_VERSION = false -- set to true to use upright sprites instead of me local l_visual = "mesh" local l_visual_size = {x=.75, y=.75} local l_clown_mesh = "animal_clownfish.b3d" - local l_trop_mesh = "fish_blue_white.b3d" + local l_trop_mesh = "fish_blue_white.b3d" local l_clown_textures = { {"clownfish.png"}, {"clownfish2.png"} @@ -34,7 +34,7 @@ local SPRITE_VERSION = false -- set to true to use upright sprites instead of me l_visual = "upright_sprite" l_visual_size = {x=.5, y=.5} l_clown_mesh = nil - l_trop_mesh = nil + l_trop_mesh = nil l_clown_textures = {{"animal_clownfish_clownfish_item.png"}} l_trop_textures = {{"animal_fish_blue_white_fish_blue_white_item.png"}} end diff --git a/mobs_sharks/init.lua b/mobs_sharks/init.lua index 9e3ade0..37686f8 100644 --- a/mobs_sharks/init.lua +++ b/mobs_sharks/init.lua @@ -63,22 +63,11 @@ if mobs.mod and mobs.mod == "redo" then lava_damage = 10, light_damage = 0, animation = l_anims, - do_custom = function(self) - if HELP_WITH_EXPERIMENT then - local p = self.object:getpos() - local a = self.object:getvelocity() - if p.y > 0 and a.y > 0 then - a.y = -1 - else - local r = math.random(100) - if r >= 1 and r <=25 then a.y = 0.25 - elseif r > 25 and r <= 50 then a.y = 0 - elseif r > 50 and r <= 75 then a.y = -0.25 - end - end - self.object:setvelocity(a) - end - end + jump = false, + stepheight = 0.1, + drops = { + {name = "mobs:meat_raw", chance = 1, min = 1, max = 3}, + }, }) --name, nodes, neighbours, minlight, maxlight, interval, chance, active_object_count, min_height, max_height mobs:spawn_specific("mobs_sharks:shark_lg", l_spawn_in, l_spawn_near, -1, 20, 30, l_spawn_chance, 1, -31000, 0) @@ -111,7 +100,12 @@ if mobs.mod and mobs.mod == "redo" then water_damage = 0, lava_damage = 10, light_damage = 0, - animation = l_anims + animation = l_anims, + jump = false, + stepheight = 0.1, + drops = { + {name = "mobs:meat_raw", chance = 1, min = 1, max = 3}, + }, }) --name, nodes, neighbours, minlight, maxlight, interval, chance, active_object_count, min_height, max_height mobs:spawn_specific("mobs_sharks:shark_md", l_spawn_in, l_spawn_near, -1, 20, 30, l_spawn_chance, 1, -31000, 0) @@ -144,7 +138,12 @@ if mobs.mod and mobs.mod == "redo" then water_damage = 0, lava_damage = 10, light_damage = 0, - animation = l_anims + animation = l_anims, + jump = false, + stepheight = 0.1, + drops = { + {name = "mobs:meat_raw", chance = 1, min = 1, max = 3}, + }, }) --name, nodes, neighbours, minlight, maxlight, interval, chance, active_object_count, min_height, max_height mobs:spawn_specific("mobs_sharks:shark_sm", l_spawn_in, l_spawn_near, -1, 20, 30, l_spawn_chance, 1, -31000, 0) diff --git a/mobs_turtles/init.lua b/mobs_turtles/init.lua index a24028c..14f6587 100644 --- a/mobs_turtles/init.lua +++ b/mobs_turtles/init.lua @@ -48,6 +48,9 @@ if mobs.mod and mobs.mod == "redo" then light_damage = 0, fall_damage = 1, animation = l_anims, + drops = { + {name = "mobs:meat_raw", chance = 1, min = 1, max = 3}, + }, follow = "farming:carrot", on_rightclick = function(self, clicker) self.state = "" @@ -94,6 +97,9 @@ if mobs.mod and mobs.mod == "redo" then light_damage = 0, fall_damage = 0, animation = l_anims, + drops = { + {name = "mobs:meat_raw", chance = 1, min = 1, max = 3}, + }, on_rightclick = function(self, clicker) mobs:capture_mob(self, clicker, 0, 0, 80, true, nil) end