    001    package net.minecraft.src;
    002
    003    import cpw.mods.fml.common.Side;
    004    import cpw.mods.fml.common.asm.SideOnly;
    005    import org.lwjgl.opengl.GL11;
    006
    007    @SideOnly(Side.CLIENT)
    008    public class RenderSheep extends RenderLiving
    009    {
    010        public RenderSheep(ModelBase par1ModelBase, ModelBase par2ModelBase, float par3)
    011        {
    012            super(par1ModelBase, par3);
    013            this.setRenderPassModel(par2ModelBase);
    014        }
    015
    016        protected int setWoolColorAndRender(EntitySheep par1EntitySheep, int par2, float par3)
    017        {
    018            if (par2 == 0 && !par1EntitySheep.getSheared())
    019            {
    020                this.loadTexture("/mob/sheep_fur.png");
    021                float var4 = 1.0F;
    022                int var5 = par1EntitySheep.getFleeceColor();
    023                GL11.glColor3f(var4 * EntitySheep.fleeceColorTable[var5][0], var4 * EntitySheep.fleeceColorTable[var5][1], var4 * EntitySheep.fleeceColorTable[var5][2]);
    024                return 1;
    025            }
    026            else
    027            {
    028                return -1;
    029            }
    030        }
    031
    032        /**
    033         * Queries whether should render the specified pass or not.
    034         */
    035        protected int shouldRenderPass(EntityLiving par1EntityLiving, int par2, float par3)
    036        {
    037            return this.setWoolColorAndRender((EntitySheep)par1EntityLiving, par2, par3);
    038        }
    039    }