From f9b1d8a9e1f672906434e7289ff9ed69c86fdbfc Mon Sep 17 00:00:00 2001 From: mcrcortex <18544518+MCRcortex@users.noreply.github.com> Date: Wed, 2 Jul 2025 18:53:45 +1000 Subject: [PATCH] Check render type before baking model --- .../voxy/client/core/model/bakery/ModelTextureBakery.java | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/main/java/me/cortex/voxy/client/core/model/bakery/ModelTextureBakery.java b/src/main/java/me/cortex/voxy/client/core/model/bakery/ModelTextureBakery.java index 905e9305..e4a70a31 100644 --- a/src/main/java/me/cortex/voxy/client/core/model/bakery/ModelTextureBakery.java +++ b/src/main/java/me/cortex/voxy/client/core/model/bakery/ModelTextureBakery.java @@ -1,9 +1,6 @@ package me.cortex.voxy.client.core.model.bakery; -import net.minecraft.block.BlockState; -import net.minecraft.block.Blocks; -import net.minecraft.block.FluidBlock; -import net.minecraft.block.LeavesBlock; +import net.minecraft.block.*; import net.minecraft.block.entity.BlockEntity; import net.minecraft.client.MinecraftClient; import net.minecraft.client.render.BlockRenderLayer; @@ -59,6 +56,9 @@ public class ModelTextureBakery { } private void bakeBlockModel(BlockState state, BlockRenderLayer layer) { + if (state.getRenderType() == BlockRenderType.INVISIBLE) { + return;//Dont bake if invisible + } var model = MinecraftClient.getInstance() .getBakedModelManager() .getBlockModels()