Class BeaconRenderer
java.lang.Object
net.minecraft.client.renderer.blockentity.BeaconRenderer
- All Implemented Interfaces:
BlockEntityRenderer<BeaconBlockEntity>
,IBlockEntityRendererExtension<BeaconBlockEntity>
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprivate static void
addVertex
(PoseStack.Pose pPose, VertexConsumer pConsumer, int pColor, int pY, float pX, float pZ, float pU, float pV) getRenderBoundingBox
(BeaconBlockEntity blockEntity) Return anAABB
that controls the visible scope of thisBlockEntityRenderer
.int
void
render
(BeaconBlockEntity pBlockEntity, float pPartialTick, PoseStack pPoseStack, MultiBufferSource pBufferSource, int pPackedLight, int pPackedOverlay) private static void
renderBeaconBeam
(PoseStack pPoseStack, MultiBufferSource pBufferSource, float pPartialTick, long pGameTime, int pYOffset, int pHeight, int pColor) static void
renderBeaconBeam
(PoseStack pPoseStack, MultiBufferSource pBufferSource, ResourceLocation pBeamLocation, float pPartialTick, float pTextureScale, long pGameTime, int pYOffset, int pHeight, int pColor, float pBeamRadius, float pGlowRadius) private static void
renderPart
(PoseStack pPoseStack, VertexConsumer pConsumer, int pColor, int pMinY, int pMaxY, float pX1, float pZ1, float pX2, float pZ2, float pX3, float pZ3, float pX4, float pZ4, float pMinU, float pMaxU, float pMinV, float pMaxV) private static void
renderQuad
(PoseStack.Pose pPose, VertexConsumer pConsumer, int pColor, int pMinY, int pMaxY, float pMinX, float pMinZ, float pMaxX, float pMaxZ, float pMinU, float pMaxU, float pMinV, float pMaxV) boolean
shouldRender
(BeaconBlockEntity pBlockEntity, Vec3 pCameraPos) boolean
shouldRenderOffScreen
(BeaconBlockEntity pBlockEntity)
-
Field Details
-
BEAM_LOCATION
-
MAX_RENDER_Y
public static final int MAX_RENDER_Y- See Also:
-
-
Constructor Details
-
BeaconRenderer
-
-
Method Details
-
render
public void render(BeaconBlockEntity pBlockEntity, float pPartialTick, PoseStack pPoseStack, MultiBufferSource pBufferSource, int pPackedLight, int pPackedOverlay) - Specified by:
render
in interfaceBlockEntityRenderer<BeaconBlockEntity>
-
renderBeaconBeam
private static void renderBeaconBeam(PoseStack pPoseStack, MultiBufferSource pBufferSource, float pPartialTick, long pGameTime, int pYOffset, int pHeight, int pColor) -
renderBeaconBeam
public static void renderBeaconBeam(PoseStack pPoseStack, MultiBufferSource pBufferSource, ResourceLocation pBeamLocation, float pPartialTick, float pTextureScale, long pGameTime, int pYOffset, int pHeight, int pColor, float pBeamRadius, float pGlowRadius) -
renderPart
private static void renderPart(PoseStack pPoseStack, VertexConsumer pConsumer, int pColor, int pMinY, int pMaxY, float pX1, float pZ1, float pX2, float pZ2, float pX3, float pZ3, float pX4, float pZ4, float pMinU, float pMaxU, float pMinV, float pMaxV) -
renderQuad
private static void renderQuad(PoseStack.Pose pPose, VertexConsumer pConsumer, int pColor, int pMinY, int pMaxY, float pMinX, float pMinZ, float pMaxX, float pMaxZ, float pMinU, float pMaxU, float pMinV, float pMaxV) -
addVertex
private static void addVertex(PoseStack.Pose pPose, VertexConsumer pConsumer, int pColor, int pY, float pX, float pZ, float pU, float pV) -
shouldRenderOffScreen
- Specified by:
shouldRenderOffScreen
in interfaceBlockEntityRenderer<BeaconBlockEntity>
-
getViewDistance
public int getViewDistance()- Specified by:
getViewDistance
in interfaceBlockEntityRenderer<BeaconBlockEntity>
-
shouldRender
- Specified by:
shouldRender
in interfaceBlockEntityRenderer<BeaconBlockEntity>
-
getRenderBoundingBox
Description copied from interface:IBlockEntityRendererExtension
Return anAABB
that controls the visible scope of thisBlockEntityRenderer
. Defaults to the unit cube at the given position.AABB.INFINITE
can be used to declare the BER should be visible everywhere.- Specified by:
getRenderBoundingBox
in interfaceIBlockEntityRendererExtension<BeaconBlockEntity>
- Returns:
- an appropriately sized
AABB
for theBlockEntityRenderer
-