Interface BlockEntityRendererRegistry
public interface BlockEntityRendererRegistry
Helper class for registering BlockEntityRenderers.
-
Field Summary
-
Method Summary
Modifier and TypeMethodDescription<E extends net.minecraft.block.entity.BlockEntity>
voidregister(net.minecraft.block.entity.BlockEntityType<E> blockEntityType, Function<net.minecraft.client.render.block.entity.BlockEntityRenderDispatcher,net.minecraft.client.render.block.entity.BlockEntityRenderer<? super E>> blockEntityRenderer)
Register a BlockEntityRenderer for a BlockEntityType.
-
Field Details
-
INSTANCE
-
-
Method Details
-
register
<E extends net.minecraft.block.entity.BlockEntity> void register(net.minecraft.block.entity.BlockEntityType<E> blockEntityType, Function<net.minecraft.client.render.block.entity.BlockEntityRenderDispatcher,net.minecraft.client.render.block.entity.BlockEntityRenderer<? super E>> blockEntityRenderer)Register a BlockEntityRenderer for a BlockEntityType. Can be called clientside before the world is rendered.- Type Parameters:
E
- theBlockEntity
- Parameters:
blockEntityType
- theBlockEntityType
to register a renderer forblockEntityRenderer
- a function that returns aBlockEntityRenderer
, called whenBlockEntityRenderDispatcher
is initialized or immediately if the dispatcher class is already loaded
-