From 2e2f56122d11d94eb6fc5b67913e0bb58dfbfa52 Mon Sep 17 00:00:00 2001 From: epCode Date: Mon, 29 May 2023 21:59:35 -0700 Subject: [PATCH] Incorperate sheep eating animation. #3734 --- mods/ENTITIES/mcl_mobs/movement.lua | 3 +++ .../mobs_mc/models/mobs_mc_sheepfur.b3d | Bin 71995 -> 74299 bytes mods/ENTITIES/mobs_mc/sheep.lua | 4 +++- 3 files changed, 6 insertions(+), 1 deletion(-) diff --git a/mods/ENTITIES/mcl_mobs/movement.lua b/mods/ENTITIES/mcl_mobs/movement.lua index 377e25f6e..df86c8161 100644 --- a/mods/ENTITIES/mcl_mobs/movement.lua +++ b/mods/ENTITIES/mcl_mobs/movement.lua @@ -480,6 +480,7 @@ end -- find and replace what mob is looking for (grass, wheat etc.) function mob_class:replace_node(pos) + if not self.replace_rate or not self.replace_what or self.child == true @@ -519,6 +520,8 @@ function mob_class:replace_node(pos) if on_replace_return ~= false then if mobs_griefing then + self.state = "eat" + self:set_animation("eat") minetest.set_node(pos, newnode) end diff --git a/mods/ENTITIES/mobs_mc/models/mobs_mc_sheepfur.b3d b/mods/ENTITIES/mobs_mc/models/mobs_mc_sheepfur.b3d index 7ee15fb553a18a438c50e362d36910af7e77c356..31044fbafe375d57aa6b28a4ed025160742095b9 100644 GIT binary patch delta 10698 zcma)>eRND`9>*_Ky}c)rXZ_n+VAdw%D+ z&&+-9{62I1aOm+rhqg>k)>5>-TUt(U*5^>(sh-V4n^h0&71^)z7)8mOHGO7$PQkpz z3k&jpa}G|e?_MCW#IwM^Y{Fh0ay>pZ!)dO}@V^XeY!3!AxmJ~&zZ@4hEPT)Q5f zY1tI->>qEgD1My+PzXn%9JS!6B}c6|YRyp?M{PK2%TYUy!a4dGN9{R!fujx_b>yfM zM-d!ZIO@z%7mi-!s4GX^IO@((4~}|r)Qh7?j(T&{hoin6MR63(Q9q7iII?mS%Ta%h z25>Zxqd1NRaTL$dOB@a6Nae`Jk;ajoBL_!AIC`0*1dfJsl*r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9&)K}=NwY3GB$=OsI5e0 zm8gVnT?u1eh1zN^v8fsjqe+|{Vk_p=7L^!kYfDQEwKb^37M1WrnzlevC z%N9muRS;W=68d5n{Ex0$&Z{<}IvdnhW8p%#vptcKgn28j*T1dO^<6fot;WYzVyQ`Z ziB6$KZ4g_D66_e7bzQ}}k2CGj){cV(YAewu4;8ze*K{A#``A?KDloZ2Z8aTihH$!J I{l3@#52hfD3jhEB diff --git a/mods/ENTITIES/mobs_mc/sheep.lua b/mods/ENTITIES/mobs_mc/sheep.lua index c71fa9b54..b4fbda52c 100644 --- a/mods/ENTITIES/mobs_mc/sheep.lua +++ b/mods/ENTITIES/mobs_mc/sheep.lua @@ -101,17 +101,19 @@ mcl_mobs.register_mob("mobs_mc:sheep", { stand_start = 0, stand_end = 0, walk_start = 0, walk_end = 40, walk_speed = 30, run_start = 0, run_end = 40, run_speed = 40, + eat_start = 40, eat_end = 80, }, child_animations = { stand_start = 81, stand_end = 81, walk_start = 81, walk_end = 121, walk_speed = 45, run_start = 81, run_end = 121, run_speed = 60, + eat_start = 121, eat_start = 161, }, follow = { "mcl_farming:wheat_item" }, view_range = 12, -- Eat grass - replace_rate = 20, + replace_rate = 40, replace_what = { { "mcl_core:dirt_with_grass", "mcl_core:dirt", -1 }, { "mcl_flowers:tallgrass", "air", 0 },