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 Details

  • Constructor Details

  • Method Details

    • addLayer

      public final boolean addLayer(RenderLayer<T,M> layer)
    • getModel

      public M getModel()
      Specified by:
      getModel in interface RenderLayerParent<T extends LivingEntity,M extends EntityModel<T>>
    • render

      public void render(T entity, float entityYaw, float partialTicks, PoseStack poseStack, MultiBufferSource buffer, int packedLight)
      Overrides:
      render in class EntityRenderer<T extends LivingEntity>
    • getRenderType

      @Nullable protected RenderType getRenderType(T livingEntity, boolean bodyVisible, boolean translucent, boolean glowing)
    • getOverlayCoords

      public static int getOverlayCoords(LivingEntity livingEntity, float u)
    • isBodyVisible

      protected boolean isBodyVisible(T livingEntity)
    • sleepDirectionToRotation

      private static float sleepDirectionToRotation(Direction facing)
    • isShaking

      protected boolean isShaking(T entity)
    • setupRotations

      protected void setupRotations(T entity, PoseStack poseStack, float bob, float yBodyRot, float partialTick, float scale)
    • getAttackAnim

      protected float getAttackAnim(T livingBase, float partialTickTime)
      Returns where in the swing animation the living entity is (from 0 to 1). Args : entity, partialTickTime
    • getBob

      protected float getBob(T livingBase, float partialTick)
      Defines what float the third param in setRotationAngles of ModelBase is
    • getFlipDegrees

      protected float getFlipDegrees(T livingEntity)
    • getWhiteOverlayProgress

      protected float getWhiteOverlayProgress(T livingEntity, float partialTicks)
    • scale

      protected void scale(T livingEntity, PoseStack poseStack, float partialTickTime)
    • shouldShowName

      protected boolean shouldShowName(T entity)
      Overrides:
      shouldShowName in class EntityRenderer<T extends LivingEntity>
    • isEntityUpsideDown

      public static boolean isEntityUpsideDown(LivingEntity entity)
    • getShadowRadius

      protected float getShadowRadius(T entity)
      Overrides:
      getShadowRadius in class EntityRenderer<T extends LivingEntity>