@Environment(value=CLIENT) public abstract class EntityRenderer<T extends Entity> extends Object
Modifier and Type | Field and Description |
---|---|
protected EntityRenderDispatcher |
dispatcher |
protected float |
shadowOpacity |
protected float |
shadowRadius |
Modifier | Constructor and Description |
---|---|
protected |
EntityRenderer(EntityRenderDispatcher dispatcher) |
Modifier and Type | Method and Description |
---|---|
protected int |
getBlockLight(T t,
BlockPos blockPos) |
TextRenderer |
getFontRenderer() |
int |
getLight(T entity,
float tickDelta) |
Vec3d |
getPositionOffset(T entity,
float tickDelta) |
EntityRenderDispatcher |
getRenderManager() |
abstract Identifier |
getTexture(T entity) |
protected boolean |
hasLabel(T entity)
Determines whether the passed entity should render with a nameplate above its head.
|
protected int |
method_27950(T t,
BlockPos blockPos) |
void |
render(T entity,
float yaw,
float tickDelta,
MatrixStack matrices,
VertexConsumerProvider vertexConsumers,
int light) |
protected void |
renderLabelIfPresent(T entity,
Text text,
MatrixStack matrices,
VertexConsumerProvider vertexConsumers,
int light) |
boolean |
shouldRender(T entity,
Frustum frustum,
double x,
double y,
double z) |
protected final EntityRenderDispatcher dispatcher
protected float shadowRadius
protected float shadowOpacity
protected EntityRenderer(EntityRenderDispatcher dispatcher)
public final int getLight(T entity, float tickDelta)
public void render(T entity, float yaw, float tickDelta, MatrixStack matrices, VertexConsumerProvider vertexConsumers, int light)
protected boolean hasLabel(T entity)
Checks for a custom nametag on living entities, and for teams/team visibilities for players.
public abstract Identifier getTexture(T entity)
public TextRenderer getFontRenderer()
protected void renderLabelIfPresent(T entity, Text text, MatrixStack matrices, VertexConsumerProvider vertexConsumers, int light)
public EntityRenderDispatcher getRenderManager()