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 pose, VertexConsumer consumer, int color, int y, float x, float z, float u, float v) getRenderBoundingBox
(BeaconBlockEntity blockEntity) Return anAABB
that controls the visible scope of thisBlockEntityRenderer
.int
void
render
(BeaconBlockEntity blockEntity, float partialTick, PoseStack poseStack, MultiBufferSource bufferSource, int packedLight, int packedOverlay) private static void
renderBeaconBeam
(PoseStack poseStack, MultiBufferSource bufferSource, float partialTick, long gameTime, int yOffset, int height, int color) static void
renderBeaconBeam
(PoseStack poseStack, MultiBufferSource bufferSource, ResourceLocation beamLocation, float partialTick, float textureScale, long gameTime, int yOffset, int height, int color, float beamRadius, float glowRadius) private static void
renderPart
(PoseStack poseStack, VertexConsumer consumer, int color, int minY, int maxY, float x1, float z1, float x2, float z2, float x3, float z3, float x4, float z4, float minU, float maxU, float minV, float maxV) private static void
renderQuad
(PoseStack.Pose pose, VertexConsumer consumer, int color, int minY, int maxY, float minX, float minZ, float maxX, float maxZ, float minU, float maxU, float minV, float maxV) boolean
shouldRender
(BeaconBlockEntity blockEntity, Vec3 cameraPos) boolean
shouldRenderOffScreen
(BeaconBlockEntity blockEntity)
-
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 blockEntity, float partialTick, PoseStack poseStack, MultiBufferSource bufferSource, int packedLight, int packedOverlay) - Specified by:
render
in interfaceBlockEntityRenderer<BeaconBlockEntity>
-
renderBeaconBeam
private static void renderBeaconBeam(PoseStack poseStack, MultiBufferSource bufferSource, float partialTick, long gameTime, int yOffset, int height, int color) -
renderBeaconBeam
public static void renderBeaconBeam(PoseStack poseStack, MultiBufferSource bufferSource, ResourceLocation beamLocation, float partialTick, float textureScale, long gameTime, int yOffset, int height, int color, float beamRadius, float glowRadius) -
renderPart
private static void renderPart(PoseStack poseStack, VertexConsumer consumer, int color, int minY, int maxY, float x1, float z1, float x2, float z2, float x3, float z3, float x4, float z4, float minU, float maxU, float minV, float maxV) -
renderQuad
private static void renderQuad(PoseStack.Pose pose, VertexConsumer consumer, int color, int minY, int maxY, float minX, float minZ, float maxX, float maxZ, float minU, float maxU, float minV, float maxV) -
addVertex
private static void addVertex(PoseStack.Pose pose, VertexConsumer consumer, int color, int y, float x, float z, float u, float v) -
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
-