From 0f77909868978e02881e8c838820f76f89aa2d23 Mon Sep 17 00:00:00 2001 From: Michieal Date: Thu, 15 Dec 2022 01:59:05 -0500 Subject: [PATCH] Attempt 2: Changed the way that the cat.on_spawn picks a texture from the list. --- mods/ENTITIES/mobs_mc/ocelot.lua | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mods/ENTITIES/mobs_mc/ocelot.lua b/mods/ENTITIES/mobs_mc/ocelot.lua index f45a78406..330203d84 100644 --- a/mods/ENTITIES/mobs_mc/ocelot.lua +++ b/mods/ENTITIES/mobs_mc/ocelot.lua @@ -162,7 +162,7 @@ cat.on_spawn = function(self) self._texture = {"mobs_mc_cat_black.png"} end if not self._texture then - local max_tex = table.maxn (cat.textures) + local max_tex = 3 -- hard coded because table.maxn() failed. self._texture = cat.textures[pr.next(1,max_tex)] -- pick a random texture. end self.object:set_properties({textures = {self._texture}})