From 0a8639837752d6b5d4718faa25d6d7d12cbed9c4 Mon Sep 17 00:00:00 2001 From: general Date: Sat, 30 Mar 2024 03:37:53 -0400 Subject: [PATCH] only show breed infotext if mob can breed * backported commit e8adf9b244770854f06efc3182f4b804d14d3947 from https://codeberg.org/tenplus1/mobs_redo/commit/e8adf9b244770854f06efc3182f4b804d14d3947 --- api.lua | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/api.lua b/api.lua index 97b646a..8f09cab 100644 --- a/api.lua +++ b/api.lua @@ -33,7 +33,7 @@ local use_mc2 = minetest.get_modpath("mcl_core") -- Global mobs = { mod = "redo", - version = "20231005", + version = "20231011", translate = S, intllib = S, invis = minetest.global_exists("invisibility") and invisibility or {}, node_ice = "default:ice", @@ -4806,7 +4806,7 @@ function mobs:feed_tame(self, clicker, feed_count, breed, tame) -- feed and tame self.food = (self.food or 0) + 1 - self._breed_countdown = feed_count - self.food + self._breed_countdown = breed and (feed_count - self.food) if self.food >= feed_count then