mirror of
https://github.com/GTNewHorizons/TinkersConstruct.git
synced 2026-11-13 17:04:24 +00:00
Make liquid rendering more resilient. Render water if the liquid icons are missing.
This commit is contained in:
1 parent
b75bb80340
commit
b03b1ac5c8
1 file changed
+5
@@ -8,6 +8,7 @@ import net.minecraft.client.renderer.Tessellator;
|
||||
import net.minecraft.init.Blocks;
|
||||
import net.minecraft.util.IIcon;
|
||||
import net.minecraft.world.IBlockAccess;
|
||||
import net.minecraftforge.fluids.FluidRegistry;
|
||||
|
||||
public class BlockSkinRenderHelper
|
||||
{
|
||||
@@ -868,6 +869,10 @@ public class BlockSkinRenderHelper
|
||||
var8 = var11;
|
||||
}
|
||||
|
||||
// safety
|
||||
if(stillIcon == null) stillIcon = FluidRegistry.WATER.getStillIcon();
|
||||
if(flowingIcon == null) flowingIcon = FluidRegistry.WATER.getFlowingIcon();
|
||||
|
||||
return Minecraft.isAmbientOcclusionEnabled() ? renderFakeBlockWithAmbientOcclusion(stillIcon, flowingIcon, x, y, z, var6, var7, var8, renderer, world) : renderFakeBlockWithColorMultiplier(
|
||||
stillIcon, flowingIcon, x, y, z, var6, var7, var8, renderer, world);
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user