From 44bd5dba6c4d1bdb962f3fffb4231c7ff0d827c4 Mon Sep 17 00:00:00 2001 From: Wuzzy Date: Tue, 10 Sep 2019 17:14:34 +0200 Subject: [PATCH] Mobs: Don't set gotten in API anymore --- mods/ENTITIES/mcl_mobs/api.lua | 7 ------- mods/ENTITIES/mcl_mobs/api.txt | 6 ++++-- 2 files changed, 4 insertions(+), 9 deletions(-) diff --git a/mods/ENTITIES/mcl_mobs/api.lua b/mods/ENTITIES/mcl_mobs/api.lua index 0cb272fb2c..0f028e8dad 100644 --- a/mods/ENTITIES/mcl_mobs/api.lua +++ b/mods/ENTITIES/mcl_mobs/api.lua @@ -1142,11 +1142,6 @@ local replace = function(self, pos) minetest.set_node(pos, {name = with}) end - -- when cow/sheep eats grass, replace wool and milk - if self.gotten == true then - self.gotten = false - self.object:set_properties(self) - end end end end @@ -3780,8 +3775,6 @@ function mobs:feed_tame(self, clicker, feed_count, breed, tame) self.horny = true end - self.gotten = false - if tame then self.tamed = true diff --git a/mods/ENTITIES/mcl_mobs/api.txt b/mods/ENTITIES/mcl_mobs/api.txt index 999ba4a850..7c2f658e27 100644 --- a/mods/ENTITIES/mcl_mobs/api.txt +++ b/mods/ENTITIES/mcl_mobs/api.txt @@ -303,8 +303,10 @@ for each mob. 'self.child_texture' contains mob child texture when growing up 'self.base_texture' contains current skin texture which was randomly selected from textures list - 'self.gotten' this is used for obtaining milk from cow and wool from - sheep + 'self.gotten' this is used to track whether some special item has been + gotten from the mob, for example, wool from sheep. + Initialized as false, and the mob must set this value + manually. 'self.horny' when animal fed enough it is set to true and animal can breed with same animal 'self.hornytimer' background timer that controls breeding functions and