Class LivingEntityRenderer<T extends LivingEntity,M extends EntityModel<T>>
java.lang.Object
net.minecraft.client.renderer.entity.EntityRenderer<T>
net.minecraft.client.renderer.entity.LivingEntityRenderer<T,M>
- All Implemented Interfaces:
RenderLayerParent<T,M>
- Direct Known Subclasses:
ArmorStandRenderer,MobRenderer,PlayerRenderer
public abstract class LivingEntityRenderer<T extends LivingEntity,M extends EntityModel<T>>
extends EntityRenderer<T>
implements RenderLayerParent<T,M>
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate static final floatprotected final List<RenderLayer<T, M>> private static final org.slf4j.Loggerprotected MFields inherited from class net.minecraft.client.renderer.entity.EntityRenderer
entityRenderDispatcher, LEASH_RENDER_STEPS, NAMETAG_SCALE, shadowRadius, shadowStrength -
Constructor Summary
ConstructorsConstructorDescriptionLivingEntityRenderer(EntityRendererProvider.Context pContext, M pModel, float pShadowRadius) -
Method Summary
Modifier and TypeMethodDescriptionfinal booleanaddLayer(RenderLayer<T, M> pLayer) protected floatgetAttackAnim(T pLivingBase, float pPartialTickTime) Returns where in the swing animation the living entity is (from 0 to 1).protected floatDefines what float the third param in setRotationAngles of ModelBase isprotected floatgetFlipDegrees(T pLivingEntity) getModel()static intgetOverlayCoords(LivingEntity pLivingEntity, float pU) protected RenderTypegetRenderType(T pLivingEntity, boolean pBodyVisible, boolean pTranslucent, boolean pGlowing) protected floatgetShadowRadius(T pEntity) protected floatgetWhiteOverlayProgress(T pLivingEntity, float pPartialTicks) protected booleanisBodyVisible(T pLivingEntity) static booleanisEntityUpsideDown(LivingEntity pEntity) protected booleanvoidrender(T pEntity, float pEntityYaw, float pPartialTicks, PoseStack pPoseStack, MultiBufferSource pBuffer, int pPackedLight) protected voidprotected voidsetupRotations(T pEntity, PoseStack pPoseStack, float pBob, float pYBodyRot, float pPartialTick, float pScale) protected booleanshouldShowName(T pEntity) private static floatsleepDirectionToRotation(Direction pFacing) Methods inherited from class net.minecraft.client.renderer.entity.EntityRenderer
getBlockLightLevel, getFont, getPackedLightCoords, getRenderOffset, getSkyLightLevel, getTextureLocation, renderNameTag, shouldRenderMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface net.minecraft.client.renderer.entity.RenderLayerParent
getTextureLocation
-
Field Details
-
LOGGER
private static final org.slf4j.Logger LOGGER -
EYE_BED_OFFSET
private static final float EYE_BED_OFFSET- See Also:
-
model
-
layers
-
-
Constructor Details
-
LivingEntityRenderer
-
-
Method Details
-
addLayer
-
getModel
- Specified by:
getModelin interfaceRenderLayerParent<T extends LivingEntity,M extends EntityModel<T>>
-
render
public void render(T pEntity, float pEntityYaw, float pPartialTicks, PoseStack pPoseStack, MultiBufferSource pBuffer, int pPackedLight) - Overrides:
renderin classEntityRenderer<T extends LivingEntity>
-
getRenderType
@Nullable protected RenderType getRenderType(T pLivingEntity, boolean pBodyVisible, boolean pTranslucent, boolean pGlowing) -
getOverlayCoords
-
isBodyVisible
-
sleepDirectionToRotation
-
isShaking
-
setupRotations
-
getAttackAnim
Returns where in the swing animation the living entity is (from 0 to 1). Args : entity, partialTickTime -
getBob
Defines what float the third param in setRotationAngles of ModelBase is -
getFlipDegrees
-
getWhiteOverlayProgress
-
scale
-
shouldShowName
- Overrides:
shouldShowNamein classEntityRenderer<T extends LivingEntity>
-
isEntityUpsideDown
-
getShadowRadius
- Overrides:
getShadowRadiusin classEntityRenderer<T extends LivingEntity>
-