Skip to content

Commit

Permalink
check for a valid MTE before rendering (GregTechCEu#2424)
Browse files Browse the repository at this point in the history
  • Loading branch information
TechLord22 authored Mar 25, 2024
1 parent c2f681f commit ba69a48
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,7 @@ public void renderItem(ItemStack rawStack, TransformType transformType) {
@Override
public boolean renderBlock(IBlockAccess world, BlockPos pos, IBlockState state, BufferBuilder buffer) {
MetaTileEntity metaTileEntity = GTUtility.getMetaTileEntity(world, pos);
if (metaTileEntity == null) {
if (metaTileEntity == null || !metaTileEntity.isValid()) {
return false;
}
CCRenderState renderState = CCRenderState.instance();
Expand Down

0 comments on commit ba69a48

Please sign in to comment.