Class PistonHeadRenderer
java.lang.Object
net.minecraft.client.renderer.blockentity.PistonHeadRenderer
- All Implemented Interfaces:
BlockEntityRenderer<PistonMovingBlockEntity, PistonHeadRenderState>, IBlockEntityRendererExtension<PistonMovingBlockEntity>
public class PistonHeadRenderer
extends Object
implements BlockEntityRenderer<PistonMovingBlockEntity, PistonHeadRenderState>
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprivate static MovingBlockRenderStatecreateMovingBlock(BlockPos pos, BlockState blockState, Holder<Biome> biome, Level level) voidextractRenderState(PistonMovingBlockEntity blockEntity, PistonHeadRenderState state, float partialTicks, Vec3 cameraPosition, @Nullable ModelFeatureRenderer.CrumblingOverlay breakProgress) getRenderBoundingBox(PistonMovingBlockEntity blockEntity) Return anAABBthat controls the visible scope of thisBlockEntityRenderer.intvoidsubmit(PistonHeadRenderState state, PoseStack poseStack, SubmitNodeCollector submitNodeCollector, CameraRenderState camera) Methods inherited from class Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface BlockEntityRenderer
shouldRender, shouldRenderOffScreen
-
Constructor Details
-
PistonHeadRenderer
public PistonHeadRenderer()
-
-
Method Details
-
createRenderState
- Specified by:
createRenderStatein interfaceBlockEntityRenderer<PistonMovingBlockEntity, PistonHeadRenderState>
-
extractRenderState
public void extractRenderState(PistonMovingBlockEntity blockEntity, PistonHeadRenderState state, float partialTicks, Vec3 cameraPosition, @Nullable ModelFeatureRenderer.CrumblingOverlay breakProgress) - Specified by:
extractRenderStatein interfaceBlockEntityRenderer<PistonMovingBlockEntity, PistonHeadRenderState>
-
submit
public void submit(PistonHeadRenderState state, PoseStack poseStack, SubmitNodeCollector submitNodeCollector, CameraRenderState camera) - Specified by:
submitin interfaceBlockEntityRenderer<PistonMovingBlockEntity, PistonHeadRenderState>
-
createMovingBlock
private static MovingBlockRenderState createMovingBlock(BlockPos pos, BlockState blockState, Holder<Biome> biome, Level level) -
getViewDistance
public int getViewDistance()- Specified by:
getViewDistancein interfaceBlockEntityRenderer<PistonMovingBlockEntity, PistonHeadRenderState>
-
getRenderBoundingBox
Description copied from interface:IBlockEntityRendererExtensionReturn anAABBthat controls the visible scope of thisBlockEntityRenderer. Defaults to the unit cube at the given position.AABB.INFINITEcan be used to declare the BER should be visible everywhere.- Specified by:
getRenderBoundingBoxin interfaceIBlockEntityRendererExtension<PistonMovingBlockEntity>- Returns:
- an appropriately sized
AABBfor theBlockEntityRenderer
-