Fix pedestals drop ClassCastException

This commit is contained in:
Aleksey 2020-12-01 13:04:12 +03:00
parent 06d54a634c
commit 2d2078f6d6
2 changed files with 13 additions and 7 deletions

View file

@ -43,6 +43,8 @@ public class PedestalItemRenderer<T extends PedestalBlockEntity> extends BlockEn
if (blockEntity.isEmpty()) return;
BlockState state = blockEntity.getWorld().getBlockState(blockEntity.getPos());
if (!(state.getBlock() instanceof BlockPedestal)) return;
ItemStack activeItem = blockEntity.getStack(0);
matrices.push();
MinecraftClient minecraft = MinecraftClient.getInstance();