Class LivingEntityRenderer<T extends LivingEntity,M extends EntityModel<T>>
java.lang.Object
net.minecraft.client.render.entity.EntityRenderer<T>
net.minecraft.client.render.entity.LivingEntityRenderer<T,M>
- All Implemented Interfaces:
FeatureRendererContext<T,M>
- Direct Known Subclasses:
ArmorStandEntityRenderer
,MobEntityRenderer
,PlayerEntityRenderer
@Environment(CLIENT) public abstract class LivingEntityRenderer<T extends LivingEntity,M extends EntityModel<T>> extends EntityRenderer<T> implements FeatureRendererContext<T,M>
- Mappings:
Namespace Name official eni
intermediary net/minecraft/class_922
named net/minecraft/client/render/entity/LivingEntityRenderer
-
Field Summary
Fields Modifier and Type Field Description protected List<FeatureRenderer<T,M>>
features
private static Logger
LOGGER
protected M
model
Fields inherited from class net.minecraft.client.render.entity.EntityRenderer
dispatcher, shadowOpacity, shadowRadius
-
Constructor Summary
Constructors Constructor Description LivingEntityRenderer(EntityRendererFactory.Context ctx, M model, float shadowRadius)
-
Method Summary
Modifier and Type Method Description protected boolean
addFeature(FeatureRenderer<T,M> feature)
protected float
getAnimationCounter(T entity, float tickDelta)
protected float
getAnimationProgress(T entity, float tickDelta)
This value is passed to other methods when calculating angles for animation.protected float
getHandSwingProgress(T entity, float tickDelta)
protected float
getLyingAngle(T entity)
M
getModel()
static int
getOverlay(LivingEntity entity, float whiteOverlayProgress)
Returns the packed overlay color for an entity, determined by its death progress and whether it is flashing.protected RenderLayer
getRenderLayer(T entity, boolean showBody, boolean translucent, boolean showOutline)
Gets the render layer appropriate for rendering the passed entity.private static float
getYaw(Direction direction)
protected boolean
hasLabel(T t)
Determines whether the passed entity should render with a nameplate above its head.protected boolean
isShaking(T entity)
Returns if this entity is shaking in the way a zombie villager, zombie, husk, or piglin undergoing conversion shakes.protected boolean
isVisible(T entity)
void
render(T t, float float2, float float3, MatrixStack matrixStack, VertexConsumerProvider vertexConsumerProvider, int int2)
protected void
scale(T entity, MatrixStack matrices, float amount)
protected void
setupTransforms(T entity, MatrixStack matrices, float animationProgress, float bodyYaw, float tickDelta)
Methods inherited from class net.minecraft.client.render.entity.EntityRenderer
getBlockLight, getFontRenderer, getLight, getPositionOffset, getSkyLight, getTexture, renderLabelIfPresent, shouldRender
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.render.entity.feature.FeatureRendererContext
getTexture
-
Field Details
-
LOGGER
- Mappings:
Namespace Name Mixin selector official a
Leni;a:Lorg/apache/logging/log4j/Logger;
intermediary field_21011
Lnet/minecraft/class_922;field_21011:Lorg/apache/logging/log4j/Logger;
named LOGGER
Lnet/minecraft/client/render/entity/LivingEntityRenderer;LOGGER:Lorg/apache/logging/log4j/Logger;
-
model
- Mappings:
Namespace Name Mixin selector official e
Leni;e:Lear;
intermediary field_4737
Lnet/minecraft/class_922;field_4737:Lnet/minecraft/class_583;
named model
Lnet/minecraft/client/render/entity/LivingEntityRenderer;model:Lnet/minecraft/client/render/entity/model/EntityModel;
-
features
- Mappings:
Namespace Name Mixin selector official f
Leni;f:Ljava/util/List;
intermediary field_4738
Lnet/minecraft/class_922;field_4738:Ljava/util/List;
named features
Lnet/minecraft/client/render/entity/LivingEntityRenderer;features:Ljava/util/List;
-
-
Constructor Details
-
LivingEntityRenderer
- Mappings:
Namespace Name Mixin selector official <init>
Leni;<init>(Lemj$a;Lear;F)V
intermediary <init>
Lnet/minecraft/class_922;<init>(Lnet/minecraft/class_5617$class_5618;Lnet/minecraft/class_583;F)V
named <init>
Lnet/minecraft/client/render/entity/LivingEntityRenderer;<init>(Lnet/minecraft/client/render/entity/EntityRendererFactory$Context;Lnet/minecraft/client/render/entity/model/EntityModel;F)V
-
-
Method Details
-
addFeature
- Mappings:
Namespace Name Mixin selector official a
Leni;a(Leql;)Z
intermediary method_4046
Lnet/minecraft/class_922;method_4046(Lnet/minecraft/class_3887;)Z
named addFeature
Lnet/minecraft/client/render/entity/LivingEntityRenderer;addFeature(Lnet/minecraft/client/render/entity/feature/FeatureRenderer;)Z
-
getModel
- Specified by:
getModel
in interfaceFeatureRendererContext<T extends LivingEntity,M extends EntityModel<T>>
- Mappings:
Namespace Name Mixin selector official a
Leob;a()Lear;
intermediary method_4038
Lnet/minecraft/class_3883;method_4038()Lnet/minecraft/class_583;
named getModel
Lnet/minecraft/client/render/entity/feature/FeatureRendererContext;getModel()Lnet/minecraft/client/render/entity/model/EntityModel;
-
render
public void render(T t, float float2, float float3, MatrixStack matrixStack, VertexConsumerProvider vertexConsumerProvider, int int2)- Overrides:
render
in classEntityRenderer<T extends LivingEntity>
- Mappings:
Namespace Name Mixin selector official a
Leni;a(Lari;FFLdlr;Lehq;I)V
intermediary method_4054
Lnet/minecraft/class_922;method_4054(Lnet/minecraft/class_1309;FFLnet/minecraft/class_4587;Lnet/minecraft/class_4597;I)V
named render
Lnet/minecraft/client/render/entity/LivingEntityRenderer;render(Lnet/minecraft/entity/LivingEntity;FFLnet/minecraft/client/util/math/MatrixStack;Lnet/minecraft/client/render/VertexConsumerProvider;I)V
-
getRenderLayer
@Nullable protected RenderLayer getRenderLayer(T entity, boolean showBody, boolean translucent, boolean showOutline)Gets the render layer appropriate for rendering the passed entity. Returns null if the entity should not be rendered.- Mappings:
Namespace Name Mixin selector official a
Leni;a(Lari;ZZZ)Lehy;
intermediary method_24302
Lnet/minecraft/class_922;method_24302(Lnet/minecraft/class_1309;ZZZ)Lnet/minecraft/class_1921;
named getRenderLayer
Lnet/minecraft/client/render/entity/LivingEntityRenderer;getRenderLayer(Lnet/minecraft/entity/LivingEntity;ZZZ)Lnet/minecraft/client/render/RenderLayer;
-
getOverlay
Returns the packed overlay color for an entity, determined by its death progress and whether it is flashing.- Mappings:
Namespace Name Mixin selector official c
Leni;c(Lari;F)I
intermediary method_23622
Lnet/minecraft/class_922;method_23622(Lnet/minecraft/class_1309;F)I
named getOverlay
Lnet/minecraft/client/render/entity/LivingEntityRenderer;getOverlay(Lnet/minecraft/entity/LivingEntity;F)I
-
isVisible
- Mappings:
Namespace Name Mixin selector official d
Leni;d(Lari;)Z
intermediary method_4056
Lnet/minecraft/class_922;method_4056(Lnet/minecraft/class_1309;)Z
named isVisible
Lnet/minecraft/client/render/entity/LivingEntityRenderer;isVisible(Lnet/minecraft/entity/LivingEntity;)Z
-
getYaw
- Mappings:
Namespace Name Mixin selector official a
Leni;a(Lgc;)F
intermediary method_18656
Lnet/minecraft/class_922;method_18656(Lnet/minecraft/class_2350;)F
named getYaw
Lnet/minecraft/client/render/entity/LivingEntityRenderer;getYaw(Lnet/minecraft/util/math/Direction;)F
-
isShaking
Returns if this entity is shaking in the way a zombie villager, zombie, husk, or piglin undergoing conversion shakes. husk, or piglin are undergoing conversion.- Mappings:
Namespace Name Mixin selector official a
Leni;a(Lari;)Z
intermediary method_25450
Lnet/minecraft/class_922;method_25450(Lnet/minecraft/class_1309;)Z
named isShaking
Lnet/minecraft/client/render/entity/LivingEntityRenderer;isShaking(Lnet/minecraft/entity/LivingEntity;)Z
-
setupTransforms
protected void setupTransforms(T entity, MatrixStack matrices, float animationProgress, float bodyYaw, float tickDelta)- Mappings:
Namespace Name Mixin selector official a
Leni;a(Lari;Ldlr;FFF)V
intermediary method_4058
Lnet/minecraft/class_922;method_4058(Lnet/minecraft/class_1309;Lnet/minecraft/class_4587;FFF)V
named setupTransforms
Lnet/minecraft/client/render/entity/LivingEntityRenderer;setupTransforms(Lnet/minecraft/entity/LivingEntity;Lnet/minecraft/client/util/math/MatrixStack;FFF)V
-
getHandSwingProgress
- Mappings:
Namespace Name Mixin selector official d
Leni;d(Lari;F)F
intermediary method_4044
Lnet/minecraft/class_922;method_4044(Lnet/minecraft/class_1309;F)F
named getHandSwingProgress
Lnet/minecraft/client/render/entity/LivingEntityRenderer;getHandSwingProgress(Lnet/minecraft/entity/LivingEntity;F)F
-
getAnimationProgress
This value is passed to other methods when calculating angles for animation. It's typically just the sum of the entity's age (in ticks) and the passed in tickDelta.- Mappings:
Namespace Name Mixin selector official a
Leni;a(Lari;F)F
intermediary method_4045
Lnet/minecraft/class_922;method_4045(Lnet/minecraft/class_1309;F)F
named getAnimationProgress
Lnet/minecraft/client/render/entity/LivingEntityRenderer;getAnimationProgress(Lnet/minecraft/entity/LivingEntity;F)F
-
getLyingAngle
- Mappings:
Namespace Name Mixin selector official c
Leni;c(Lari;)F
intermediary method_4039
Lnet/minecraft/class_922;method_4039(Lnet/minecraft/class_1309;)F
named getLyingAngle
Lnet/minecraft/client/render/entity/LivingEntityRenderer;getLyingAngle(Lnet/minecraft/entity/LivingEntity;)F
-
getAnimationCounter
- Mappings:
Namespace Name Mixin selector official b
Leni;b(Lari;F)F
intermediary method_23185
Lnet/minecraft/class_922;method_23185(Lnet/minecraft/class_1309;F)F
named getAnimationCounter
Lnet/minecraft/client/render/entity/LivingEntityRenderer;getAnimationCounter(Lnet/minecraft/entity/LivingEntity;F)F
-
scale
- Mappings:
Namespace Name Mixin selector official a
Leni;a(Lari;Ldlr;F)V
intermediary method_4042
Lnet/minecraft/class_922;method_4042(Lnet/minecraft/class_1309;Lnet/minecraft/class_4587;F)V
named scale
Lnet/minecraft/client/render/entity/LivingEntityRenderer;scale(Lnet/minecraft/entity/LivingEntity;Lnet/minecraft/client/util/math/MatrixStack;F)V
-
hasLabel
Description copied from class:EntityRenderer
Determines whether the passed entity should render with a nameplate above its head.Checks for a custom nametag on living entities, and for teams/team visibilities for players.
- Overrides:
hasLabel
in classEntityRenderer<T extends LivingEntity>
- Mappings:
Namespace Name Mixin selector official b
Leni;b(Lari;)Z
intermediary method_4055
Lnet/minecraft/class_922;method_4055(Lnet/minecraft/class_1309;)Z
named hasLabel
Lnet/minecraft/client/render/entity/LivingEntityRenderer;hasLabel(Lnet/minecraft/entity/LivingEntity;)Z
-