gt:                 float f1 = (float)(i >> 24 & 255) / 255.0F;
context: package net.minecraft.client.renderer.entity;
  
  import com.google.common.collect.Lists;
  import java.nio.FloatBuffer;
  import java.util.List;
  import net.minecraft.client.Minecraft;
  import net.minecraft.client.entity.EntityPlayerSP;
  import net.minecraft.client.model.ModelBase;
  import net.minecraft.client.renderer.GLAllocation;
  import net.minecraft.client.renderer.GlStateManager;
  import net.minecraft.client.renderer.OpenGlHelper;
  import net.minecraft.client.renderer.entity.layers.LayerRenderer;
  import net.minecraft.client.renderer.texture.DynamicTexture;
  import net.minecraft.entity.EntityLivingBase;
  import net.minecraft.entity.player.EntityPlayer;
  import net.minecraft.entity.player.EnumPlayerModelParts;
  import net.minecraft.scoreboard.Team;
  import net.minecraft.util.math.MathHelper;
  import net.minecraft.util.text.TextFormatting;
  import org.apache.logging.log4j.LogManager;
  import org.apache.logging.log4j.Logger;
  
  public abstract class RenderLivingBase<T extends EntityLivingBase> extends Render<T>
  {
      private static final Logger LOGGER = LogManager.getLogger();
      private static final DynamicTexture TEXTURE_BRIGHTNESS = new DynamicTexture(16, 16);
      protected ModelBase mainModel;
      protected FloatBuffer brightnessBuffer = GLAllocation.createDirectFloatBuffer(4);
      protected List<LayerRenderer<T>> layerRenderers = Lists.<LayerRenderer<T>>newArrayList();
      protected boolean renderMarker;
  
      public RenderLivingBase(RenderManager renderManagerIn, ModelBase modelBaseIn, float shadowSizeIn)
      {
          super(renderManagerIn);
          this.mainModel = modelBaseIn;
          this.shadowSize = shadowSizeIn;
      }
  
      protected <V extends EntityLivingBase, U extends LayerRenderer<V>> boolean addLayer(U layer)
      {
          return this.layerRenderers.add((LayerRenderer<T>)layer);
      }
  
      protected <V extends EntityLivingBase, U extends LayerRenderer<V>> boolean removeLayer(U layer)
      {
          return this.layerRenderers.remove(layer);
      }
  
      public ModelBase getMainModel()
      {
          return this.mainModel;
      }
  
      /**
       * Returns a rotation angle that is inbetween two other rotation angles. par1 and par2 are the angles between which
       * to interpolate, par3 is probably a float between 0.0 and 1.0 that tells us where "between" the two angles we are.
       * Example: par1 = 30, par2 = 50, par3 = 0.5, then return = 40
       */
      protected float interpolateRotation(float prevYawOffset, float yawOffset, float partialTicks)
      {
          float f;
  
          for (f = yawOffset - prevYawOffset; f < -180.0F; f += 360.0F)
          {
              ;
          }
  
          while (f >= 180.0F)
          {
              f -= 360.0F;
          }
  
          return prevYawOffset + partialTicks * f;
      }
  
      public void transformHeldFull3DItemLayer()
      {
      }
  
      /**
       * Renders the desired {@code T} type Entity.
       */
      public void doRender(T entity, double x, double y, double z, float entityYaw, float partialTicks)
      {
          GlStateManager.pushMatrix();
          GlStateManager.disableCull();
          this.mainModel.swingProgress = this.getSwingProgress(entity, partialTicks);
          this.mainModel.isRiding = entity.isRiding();
          this.mainModel.isChild = entity.isChild();
  
          try
          {
              float f = this.interpolateRotation(entity.prevRenderYawOffset, entity.renderYawOffset, partialTicks);
              float f1 = this.interpolateRotation(entity.prevRotationYawHead, entity.rotationYawHead, partialTicks);
              float f2 = f1 - f;
  
              if (entity.isRiding() && entity.getRidingEntity() instanceof EntityLivingBase)
              {
                  EntityLivingBase entitylivingbase = (EntityLivingBase)entity.getRidingEntity();
                  f = this.interpolateRotation(entitylivingbase.prevRenderYawOffset, entitylivingbase.renderYawOffset, partialTicks);
                  f2 = f1 - f;
                  float f3 = MathHelper.wrapDegrees(f2);
  
                  if (f3 < -85.0F)
                  {
                      f3 = -85.0F;
                  }
  
                  if (f3 >= 85.0F)
                  {
                      f3 = 85.0F;
                  }
  
                  f = f1 - f3;
  
                  if (f3 * f3 > 2500.0F)
                  {
                      f += f3 * 0.2F;
                  }
              }
  
              float f7 = entity.prevRotationPitch + (entity.rotationPitch - entity.prevRotationPitch) * partialTicks;
              this.renderLivingAt(entity, x, y, z);
              float f8 = this.handleRotationFloat(entity, partialTicks);
              this.rotateCorpse(entity, f8, f, partialTicks);
              float f4 = this.prepareScale(entity, partialTicks);
              float f5 = 0.0F;
              float f6 = 0.0F;
  
              if (!entity.isRiding())
              {
                  f5 = entity.prevLimbSwingAmount + (entity.limbSwingAmount - entity.prevLimbSwingAmount) * partialTicks;
                  f6 = entity.limbSwing - entity.limbSwingAmount * (1.0F - partialTicks);
  
                  if (entity.isChild())
                  {
                      f6 *= 3.0F;
                  }
  
                  if (f5 > 1.0F)
                  {
                      f5 = 1.0F;
                  }
              }
  
              GlStateManager.enableAlpha();
              this.mainModel.setLivingAnimations(entity, f6, f5, partialTicks);
              this.mainModel.setRotationAngles(f6, f5, f8, f2, f7, f4, entity);
  
              if (this.renderOutlines)
              {
                  boolean flag1 = this.setScoreTeamColor(entity);
                  GlStateManager.enableColorMaterial();
                  GlStateManager.enableOutlineMode(this.getTeamColor(entity));
  
                  if (!this.renderMarker)
                  {
                      this.renderModel(entity, f6, f5, f8, f2, f7, f4);
                  }
  
                  if (!(entity instanceof EntityPlayer) || !((EntityPlayer)entity).isSpectator())
                  {
                      this.renderLayers(entity, f6, f5, partialTicks, f8, f2, f7, f4);
                  }
  
                  GlStateManager.disableOutlineMode();
                  GlStateManager.disableColorMaterial();
  
                  if (flag1)
                  {
                      this.unsetScoreTeamColor();
                  }
              }
              else
              {
                  boolean flag = this.setDoRenderBrightness(entity, partialTicks);
                  this.renderModel(entity, f6, f5, f8, f2, f7, f4);
  
                  if (flag)
                  {
                      this.unsetBrightness();
                  }
  
                  GlStateManager.depthMask(true);
  
                  if (!(entity instanceof EntityPlayer) || !((EntityPlayer)entity).isSpectator())
                  {
                      this.renderLayers(entity, f6, f5, partialTicks, f8, f2, f7, f4);
                  }
              }
  
              GlStateManager.disableRescaleNormal();
          }
          catch (Exception exception)
          {
              LOGGER.error((String)"Couldn\'t render entity", (Throwable)exception);
          }
  
          GlStateManager.setActiveTexture(OpenGlHelper.lightmapTexUnit);
          GlStateManager.enableTexture2D();
          GlStateManager.setActiveTexture(OpenGlHelper.defaultTexUnit);
          GlStateManager.enableCull();
          GlStateManager.popMatrix();
          super.doRender(entity, x, y, z, entityYaw, partialTicks);
      }
  
      public float prepareScale(T entitylivingbaseIn, float partialTicks)
      {
          GlStateManager.enableRescaleNormal();
          GlStateManager.scale(-1.0F, -1.0F, 1.0F);
          this.preRenderCallback(entitylivingbaseIn, partialTicks);
          float f = 0.0625F;
          GlStateManager.translate(0.0F, -1.501F, 0.0F);
          return 0.0625F;
      }
  
      protected boolean setScoreTeamColor(T entityLivingBaseIn)
      {
          GlStateManager.disableLighting();
          GlStateManager.setActiveTexture(OpenGlHelper.lightmapTexUnit);
          GlStateManager.disableTexture2D();
          GlStateManager.setActiveTexture(OpenGlHelper.defaultTexUnit);
          return true;
      }
  
      protected void unsetScoreTeamColor()
      {
          GlStateManager.enableLighting();
          GlStateManager.setActiveTexture(OpenGlHelper.lightmapTexUnit);
          GlStateManager.enableTexture2D();
          GlStateManager.setActiveTexture(OpenGlHelper.defaultTexUnit);
      }
  
      /**
       * Renders the model in RenderLiving
       */
      protected void renderModel(T entitylivingbaseIn, float limbSwing, float limbSwingAmount, float ageInTicks, float netHeadYaw, float headPitch, float scaleFactor)
      {
          boolean flag = !entitylivingbaseIn.isInvisible() || this.renderOutlines;
          boolean flag1 = !flag && !entitylivingbaseIn.isInvisibleToPlayer(Minecraft.getMinecraft().thePlayer);
  
          if (flag || flag1)
          {
              if (!this.bindEntityTexture(entitylivingbaseIn))
              {
                  return;
              }
  
              if (flag1)
              {
                  GlStateManager.enableBlendProfile(GlStateManager.Profile.TRANSPARENT_MODEL);
              }
  
              this.mainModel.render(entitylivingbaseIn, limbSwing, limbSwingAmount, ageInTicks, netHeadYaw, headPitch, scaleFactor);
  
              if (flag1)
              {
                  GlStateManager.disableBlendProfile(GlStateManager.Profile.TRANSPARENT_MODEL);
              }
          }
      }
  
      protected boolean setDoRenderBrightness(T entityLivingBaseIn, float partialTicks)
      {
          return this.setBrightness(entityLivingBaseIn, partialTicks, true);
      }
  
      protected boolean setBrightness(T entitylivingbaseIn, float partialTicks, boolean combineTextures)
      {
          float f = entitylivingbaseIn.getBrightness(partialTicks);
          int i = this.getColorMultiplier(entitylivingbaseIn, f, partialTicks);
          boolean flag = (i >> 24 & 255) > 0;
          boolean flag1 = entitylivingbaseIn.hurtTime > 0 || entitylivingbaseIn.deathTime > 0;
  
          if (!flag && !flag1)
          {
              return false;
          }
          else if (!flag && !combineTextures)
          {
              return false;
          }
          else
          {
              GlStateManager.setActiveTexture(OpenGlHelper.defaultTexUnit);
              GlStateManager.enableTexture2D();
              GlStateManager.glTexEnvi(8960, 8704, OpenGlHelper.GL_COMBINE);
              GlStateManager.glTexEnvi(8960, OpenGlHelper.GL_COMBINE_RGB, 8448);
              GlStateManager.glTexEnvi(8960, OpenGlHelper.GL_SOURCE0_RGB, OpenGlHelper.defaultTexUnit);
              GlStateManager.glTexEnvi(8960, OpenGlHelper.GL_SOURCE1_RGB, OpenGlHelper.GL_PRIMARY_COLOR);
              GlStateManager.glTexEnvi(8960, OpenGlHelper.GL_OPERAND0_RGB, 768);
              GlStateManager.glTexEnvi(8960, OpenGlHelper.GL_OPERAND1_RGB, 768);
              GlStateManager.glTexEnvi(8960, OpenGlHelper.GL_COMBINE_ALPHA, 7681);
              GlStateManager.glTexEnvi(8960, OpenGlHelper.GL_SOURCE0_ALPHA, OpenGlHelper.defaultTexUnit);
              GlStateManager.glTexEnvi(8960, OpenGlHelper.GL_OPERAND0_ALPHA, 770);
              GlStateManager.setActiveTexture(OpenGlHelper.lightmapTexUnit);
              GlStateManager.enableTexture2D();
              GlStateManager.glTexEnvi(8960, 8704, OpenGlHelper.GL_COMBINE);
              GlStateManager.glTexEnvi(8960, OpenGlHelper.GL_COMBINE_RGB, OpenGlHelper.GL_INTERPOLATE);
              GlStateManager.glTexEnvi(8960, OpenGlHelper.GL_SOURCE0_RGB, OpenGlHelper.GL_CONSTANT);
              GlStateManager.glTexEnvi(8960, OpenGlHelper.GL_SOURCE1_RGB, OpenGlHelper.GL_PREVIOUS);
              GlStateManager.glTexEnvi(8960, OpenGlHelper.GL_SOURCE2_RGB, OpenGlHelper.GL_CONSTANT);
              GlStateManager.glTexEnvi(8960, OpenGlHelper.GL_OPERAND0_RGB, 768);
              GlStateManager.glTexEnvi(8960, OpenGlHelper.GL_OPERAND1_RGB, 768);
              GlStateManager.glTexEnvi(8960, OpenGlHelper.GL_OPERAND2_RGB, 770);
              GlStateManager.glTexEnvi(8960, OpenGlHelper.GL_COMBINE_ALPHA, 7681);
              GlStateManager.glTexEnvi(8960, OpenGlHelper.GL_SOURCE0_ALPHA, OpenGlHelper.GL_PREVIOUS);
              GlStateManager.glTexEnvi(8960, OpenGlHelper.GL_OPERAND0_ALPHA, 770);
              this.brightnessBuffer.position(0);
  
              if (flag1)
              {
                  this.brightnessBuffer.put(1.0F);
                  this.brightnessBuffer.put(0.0F);
                  this.brightnessBuffer.put(0.0F);
                  this.brightnessBuffer.put(0.3F);
              }
              else
              {
  