Class RenderBlockEntityModel<T extends CyclopsBlockEntity,M>
java.lang.Object
org.cyclops.cyclopscore.client.render.blockentity.RenderBlockEntityModel<T,M>
- All Implemented Interfaces:
net.minecraft.client.renderer.blockentity.BlockEntityRenderer<T>
- Direct Known Subclasses:
RenderBlockEntityModelBase
public abstract class RenderBlockEntityModel<T extends CyclopsBlockEntity,M>
extends Object
implements net.minecraft.client.renderer.blockentity.BlockEntityRenderer<T>
General renderer for
CyclopsBlockEntity
with models.-
Field Summary
-
Constructor Summary
ConstructorDescriptionRenderBlockEntityModel
(M model, net.minecraft.client.resources.model.Material material) Make a new instance. -
Method Summary
Modifier and TypeMethodDescriptionnet.minecraft.client.resources.model.Material
Get the material.getModel()
Function<net.minecraft.resources.ResourceLocation,
net.minecraft.client.renderer.RenderType> protected void
postRotate
(T tile, com.mojang.blaze3d.vertex.PoseStack matrixStack) protected void
void
render
(T tile, float partialTick, com.mojang.blaze3d.vertex.PoseStack matrixStack, net.minecraft.client.renderer.MultiBufferSource buffer, int combinedLight, int combinedOverlay) protected abstract void
renderModel
(T tile, M model, float partialTick, com.mojang.blaze3d.vertex.PoseStack matrixStack, com.mojang.blaze3d.vertex.VertexConsumer vertexBuilder, net.minecraft.client.renderer.MultiBufferSource buffer, int combinedLight, int combinedOverlay) Render the actual model, override this to change the way the model should be rendered.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface net.minecraft.client.renderer.blockentity.BlockEntityRenderer
getViewDistance, shouldRender, shouldRenderOffScreen
-
Field Details
-
model
-
-
Constructor Details
-
RenderBlockEntityModel
Make a new instance.- Parameters:
model
- The model to render.material
- The material to render the model with.
-
-
Method Details
-
getModel
-
getMaterial
public net.minecraft.client.resources.model.Material getMaterial()Get the material.- Returns:
- The material.
-
getRenderTypeGetter
public Function<net.minecraft.resources.ResourceLocation,net.minecraft.client.renderer.RenderType> getRenderTypeGetter() -
preRotate
-
postRotate
-
render
public void render(T tile, float partialTick, com.mojang.blaze3d.vertex.PoseStack matrixStack, net.minecraft.client.renderer.MultiBufferSource buffer, int combinedLight, int combinedOverlay) - Specified by:
render
in interfacenet.minecraft.client.renderer.blockentity.BlockEntityRenderer<T extends CyclopsBlockEntity>
-
renderModel
protected abstract void renderModel(T tile, M model, float partialTick, com.mojang.blaze3d.vertex.PoseStack matrixStack, com.mojang.blaze3d.vertex.VertexConsumer vertexBuilder, net.minecraft.client.renderer.MultiBufferSource buffer, int combinedLight, int combinedOverlay) Render the actual model, override this to change the way the model should be rendered.- Parameters:
tile
- The tile entity.model
- The base model.partialTick
- The partial tick value.matrixStack
- The matrix stack.vertexBuilder
- The vertex builder.buffer
- The render type buffer.combinedLight
- The combined light value.combinedOverlay
- The combined overlay value.
-