diff --git a/mods/ENTITIES/mcl_mobs/api/api.lua b/mods/ENTITIES/mcl_mobs/api/api.lua index 4447c1587..de21cf948 100644 --- a/mods/ENTITIES/mcl_mobs/api/api.lua +++ b/mods/ENTITIES/mcl_mobs/api/api.lua @@ -417,7 +417,7 @@ function mobs:register_mob(name, def) --on_breed = def.on_breed, - --on_grown = def.on_grown, + on_grown = def.on_grown, --on_detach_child = mob_detach_child, diff --git a/mods/ENTITIES/mcl_mobs/api/mob_functions/breeding.lua b/mods/ENTITIES/mcl_mobs/api/mob_functions/breeding.lua index 330fcb0a6..e911a816b 100644 --- a/mods/ENTITIES/mcl_mobs/api/mob_functions/breeding.lua +++ b/mods/ENTITIES/mcl_mobs/api/mob_functions/breeding.lua @@ -146,11 +146,12 @@ end --make the baby grow up mobs.baby_grow_up = function(self) - self.baby = nil - self.visual_size = self.backup_visual_size - self.collisionbox = self.backup_collisionbox - self.selectionbox = self.backup_selectionbox - self.object:set_properties(self) + self.baby = nil + self.visual_size = self.backup_visual_size + self.collisionbox = self.backup_collisionbox + self.selectionbox = self.backup_selectionbox + self.object:set_properties(self) + if self.on_grown then self.on_grown(self) end end --makes the baby grow up faster with diminishing returns diff --git a/mods/ENTITIES/mobs_mc/models/mobs_mc_sheepfur.b3d b/mods/ENTITIES/mobs_mc/models/mobs_mc_sheepfur.b3d index 66af0015f..b909a5142 100644 Binary files a/mods/ENTITIES/mobs_mc/models/mobs_mc_sheepfur.b3d and b/mods/ENTITIES/mobs_mc/models/mobs_mc_sheepfur.b3d differ diff --git a/mods/ENTITIES/mobs_mc/models/mobs_mc_sheepfur.blend b/mods/ENTITIES/mobs_mc/models/mobs_mc_sheepfur.blend new file mode 100644 index 000000000..80db0c986 Binary files /dev/null and b/mods/ENTITIES/mobs_mc/models/mobs_mc_sheepfur.blend differ diff --git a/mods/ENTITIES/mobs_mc/sheep.lua b/mods/ENTITIES/mobs_mc/sheep.lua index f7582bebf..c074eb1f2 100644 --- a/mods/ENTITIES/mobs_mc/sheep.lua +++ b/mods/ENTITIES/mobs_mc/sheep.lua @@ -82,16 +82,16 @@ mobs:register_mob("mobs_mc:sheep", { --head code has_head = true, - head_bone = {"hea1", "hea2",}, + head_bone = "head", swap_y_with_x = false, reverse_head_yaw = false, - head_bone_pos_y = 3.6, - head_bone_pos_z = -0.6, + head_bone_pos_y = 0, + head_bone_pos_z = 0, - head_height_offset = 1.0525, - head_direction_offset = 0.5, + head_height_offset = 1.2, + head_direction_offset = 0, head_pitch_modifier = 0, --end head code @@ -117,7 +117,7 @@ mobs:register_mob("mobs_mc:sheep", { }, animation = { speed_normal = 25, run_speed = 65, - stand_start = 40, stand_end = 80, + stand_start = 0, stand_end = 0, walk_start = 0, walk_end = 40, run_start = 0, run_end = 40, }, @@ -330,6 +330,24 @@ mobs:register_mob("mobs_mc:sheep", { return false end end, + on_spawn = function(self) + if self.baby then + self.animation = table.copy(self.animation) + self.animation.stand_start = 81 + self.animation.stand_end = 81 + self.animation.walk_start = 81 + self.animation.walk_end = 121 + self.animation.run_start = 81 + self.animation.run_end = 121 + end + return true + end, + on_grown = function(self) + self.animation = nil + local anim = self.current_animation + self.current_animation = nil -- Mobs Redo does nothing otherwise + mobs.set_mob_animation(self, anim) + end }) mobs:spawn_specific( "mobs_mc:sheep", diff --git a/mods/ENTITIES/mobs_mc/textures/mobs_mc_sheep_fur.png b/mods/ENTITIES/mobs_mc/textures/mobs_mc_sheep_fur.png index fa447031d..9cff461b7 100644 Binary files a/mods/ENTITIES/mobs_mc/textures/mobs_mc_sheep_fur.png and b/mods/ENTITIES/mobs_mc/textures/mobs_mc_sheep_fur.png differ