Package net.minecraft.client.model

Examples of net.minecraft.client.model.ModelBiped


      ARBShaderObjects.glUniform1fARB(grainIntensityUniform, grainIntensity);
    }
  };

  public RenderDoppleganger() {
    super(new ModelBiped(0.5F), 0F);
  }
View Full Code Here


  @Override
  public void registerRenderInformation() {
   
    // renderers
    ChestItemRenderHelper.instance = new ColoniesChestRenderHelper();
    RenderingRegistry.registerEntityRenderingHandler(EntityBarbarian.class, new RenderBarbarian(new ModelBiped(), 1.0f));
    RenderingRegistry.registerEntityRenderingHandler(EntityBarbarianChief.class, new RenderBarbarianChief(new ModelBiped(), 1.0f));
 
    // old code for custom female model
    //RenderingRegistry.instance().registerEntityRenderingHandler(
    //    EntityWife.class, new RenderLiving(new ModelFemale(), 0.5F));
   
View Full Code Here

    }
  }

  public static ModelBiped getGlow(int index)
  {
    ModelBiped biped = index != 2 ? GLOW_BIG : GLOW_SMALL;

    biped.bipedHead.showModel = index == 0;
    biped.bipedHeadwear.showModel = index == 0;
    biped.bipedBody.showModel = index == 1 || index == 2;
    biped.bipedRightArm.showModel = index == 1;
View Full Code Here

    @Override
    public void render(Entity var1, float var2, float var3, float var4, float var5, float var6, float var7)
    {
        final Class<?> entityClass = EntityClientPlayerMP.class;
        final Render render = RenderManager.instance.getEntityClassRenderObject(entityClass);
        final ModelBiped modelBipedMain = ((RenderPlayer) render).modelBipedMain;

        this.usingParachute = false;
        boolean wearingMask = false;
        boolean wearingGear = false;
        boolean wearingLeftTankGreen = false;
View Full Code Here

    {
        float var1 = 0.0F;

        final Class<?> entityClass = EntityClientPlayerMP.class;
        final Render render = RenderManager.instance.getEntityClassRenderObject(entityClass);
        final ModelBiped modelBipedMain = ((RenderPlayer) render).modelBipedMain;
       
        if (this.modelPlayer.equals(modelBipedMain))
        {
            this.oxygenMask = createModelRenderer(this.modelPlayer, 0, 0, 0);
            this.oxygenMask.addBox(-4.0F, -8.0F, -4.0F, 8, 8, 8, 1);
View Full Code Here

        {
            PlayerGearData gearData = ClientProxyCore.playerItemData.get(par1EntityLivingBase.getCommandSenderName());

            if (gearData != null && !RenderPlayerGC.flagThermalOverride)
            {
                ModelBiped modelBiped;

                for (int i = 0; i < 4; ++i)
                {
                    if (i == 0)
                    {
                        modelBiped = this.modelThermalPaddingHelmet;
                    }
                    else
                    {
                        modelBiped = this.modelThermalPadding;
                    }

                    int padding = gearData.getThermalPadding(i);

                    if (padding >= 0)
                    {
                        GL11.glColor4f(1, 1, 1, 1);
                        FMLClientHandler.instance().getClient().getTextureManager().bindTexture(thermalPaddingTexture1);
                        modelBiped.bipedHead.showModel = i == 0;
                        modelBiped.bipedHeadwear.showModel = i == 0;
                        modelBiped.bipedBody.showModel = i == 1 || i == 2;
                        modelBiped.bipedRightArm.showModel = i == 1;
                        modelBiped.bipedLeftArm.showModel = i == 1;
                        modelBiped.bipedRightLeg.showModel = i == 2 || i == 3;
                        modelBiped.bipedLeftLeg.showModel = i == 2 || i == 3;
                        modelBiped.onGround = this.renderPlayer.modelBipedMain.onGround;
                        modelBiped.isRiding = this.renderPlayer.modelBipedMain.isRiding;
                        modelBiped.isChild = this.renderPlayer.modelBipedMain.isChild;
                        if (this.renderPlayer.modelBipedMain != null)
                        {
                            modelBiped.heldItemLeft = this.renderPlayer.modelBipedMain.heldItemLeft;
                            modelBiped.heldItemRight = this.renderPlayer.modelBipedMain.heldItemRight;
                            modelBiped.isSneak = this.renderPlayer.modelBipedMain.isSneak;
                            modelBiped.aimedBow = this.renderPlayer.modelBipedMain.aimedBow;
                        }
                        modelBiped.setLivingAnimations(par1EntityLivingBase, par2, par3, 0.0F);
                        modelBiped.render(par1EntityLivingBase, par2, par3, par4, par5, par6, par7);

                        // Start alpha render
                        GL11.glDisable(GL11.GL_LIGHTING);
                        FMLClientHandler.instance().getClient().getTextureManager().bindTexture(thermalPaddingTexture0);
                        GL11.glEnable(GL11.GL_ALPHA_TEST);
                        GL11.glEnable(GL11.GL_BLEND);
                        GL11.glAlphaFunc(GL11.GL_GREATER, 0.0F);
                        GL11.glBlendFunc(GL11.GL_SRC_ALPHA, GL11.GL_ONE_MINUS_SRC_ALPHA);
                        float time = par1EntityLivingBase.ticksExisted / 10.0F;
                        float sTime = (float) Math.sin(time) * 0.5F + 0.5F;

                        float r = 0.2F * sTime;
                        float g = 1.0F * sTime;
                        float b = 0.2F * sTime;

                        if (par1EntityLivingBase.worldObj.provider instanceof IGalacticraftWorldProvider)
                        {
                            float modifier = ((IGalacticraftWorldProvider) par1EntityLivingBase.worldObj.provider).getThermalLevelModifier();

                            if (modifier > 0)
                            {
                                b = g;
                                g = r;
                            }
                            else if (modifier < 0)
                            {
                                r = g;
                                g = b;
                            }
                        }

                        GL11.glColor4f(r, g, b, 0.4F * sTime);
                        modelBiped.render(par1EntityLivingBase, par2, par3, par4, par5, par6, par7);
                        GL11.glDisable(GL11.GL_BLEND);
                        GL11.glEnable(GL11.GL_ALPHA_TEST);
                        GL11.glColor4f(1, 1, 1, 1);
                        GL11.glEnable(GL11.GL_LIGHTING);
                    }
View Full Code Here

        {
            PlayerGearData gearData = ClientProxyCore.playerItemData.get(par1EntityLivingBase.getCommandSenderName());

            if (gearData != null && !RenderPlayerGC.flagThermalOverride)
            {
                ModelBiped modelBiped;

                for (int i = 0; i < 4; ++i)
                {
                    if (i == 0)
                    {
                        modelBiped = this.modelThermalPaddingHelmet;
                    }
                    else
                    {
                        modelBiped = this.modelThermalPadding;
                    }

                    int padding = gearData.getThermalPadding(i);

                    if (padding >= 0)
                    {
                        GL11.glColor4f(1, 1, 1, 1);
                        this.bindTexture(RenderPlayerGC.thermalPaddingTexture1);
                        modelBiped.bipedHead.showModel = i == 0;
                        modelBiped.bipedHeadwear.showModel = i == 0;
                        modelBiped.bipedBody.showModel = i == 1 || i == 2;
                        modelBiped.bipedRightArm.showModel = i == 1;
                        modelBiped.bipedLeftArm.showModel = i == 1;
                        modelBiped.bipedRightLeg.showModel = i == 2 || i == 3;
                        modelBiped.bipedLeftLeg.showModel = i == 2 || i == 3;
                        modelBiped.onGround = this.mainModel.onGround;
                        modelBiped.isRiding = this.mainModel.isRiding;
                        modelBiped.isChild = this.mainModel.isChild;
                        if (this.mainModel instanceof ModelBiped)
                        {
                            modelBiped.heldItemLeft = ((ModelBiped) this.mainModel).heldItemLeft;
                            modelBiped.heldItemRight = ((ModelBiped) this.mainModel).heldItemRight;
                            modelBiped.isSneak = ((ModelBiped) this.mainModel).isSneak;
                            modelBiped.aimedBow = ((ModelBiped) this.mainModel).aimedBow;
                        }
                        modelBiped.setLivingAnimations(par1EntityLivingBase, par2, par3, 0.0F);
                        modelBiped.render(par1EntityLivingBase, par2, par3, par4, par5, par6, par7);

                        // Start alpha render
                        GL11.glDisable(GL11.GL_LIGHTING);
                        this.bindTexture(RenderPlayerGC.thermalPaddingTexture0);
                        GL11.glEnable(GL11.GL_ALPHA_TEST);
                        GL11.glEnable(GL11.GL_BLEND);
                        GL11.glAlphaFunc(GL11.GL_GREATER, 0.0F);
                        GL11.glBlendFunc(GL11.GL_SRC_ALPHA, GL11.GL_ONE_MINUS_SRC_ALPHA);
                        float time = par1EntityLivingBase.ticksExisted / 10.0F;
                        float sTime = (float) Math.sin(time) * 0.5F + 0.5F;

                        float r = 0.2F * sTime;
                        float g = 1.0F * sTime;
                        float b = 0.2F * sTime;

                        if (par1EntityLivingBase.worldObj.provider instanceof IGalacticraftWorldProvider)
                        {
                            float modifier = ((IGalacticraftWorldProvider) par1EntityLivingBase.worldObj.provider).getThermalLevelModifier();

                            if (modifier > 0)
                            {
                                b = g;
                                g = r;
                            }
                            else if (modifier < 0)
                            {
                                r = g;
                                g = b;
                            }
                        }

                        GL11.glColor4f(r, g, b, 0.4F * sTime);
                        modelBiped.render(par1EntityLivingBase, par2, par3, par4, par5, par6, par7);
                        GL11.glDisable(GL11.GL_BLEND);
                        GL11.glEnable(GL11.GL_ALPHA_TEST);
                        GL11.glColor4f(1, 1, 1, 1);
                        GL11.glEnable(GL11.GL_LIGHTING);
                    }
View Full Code Here

        renderPass = pass;
    }

    public static ModelBiped getArmorModel(EntityLivingBase entityLiving, ItemStack itemStack, int slotID, ModelBiped _default)
    {
        ModelBiped modelbiped = itemStack.getItem().getArmorModel(entityLiving, itemStack, slotID);
        return modelbiped == null ? _default : modelbiped;
    }
View Full Code Here

   
    ItemArmor itemarmor = (ItemArmor)item;
    TextureManager textureManager = Minecraft.getMinecraft().getTextureManager();
    textureManager.bindTexture(RenderBiped.getArmorResource(entity, stack, slot, null));
   
    ModelBiped modelBiped = ForgeHooksClient.getArmorModel(entity, stack, slot, null);
    setRenderPassModel(modelBiped);
    if (modelBiped != null) {
      modelBiped.onGround = mainModel.onGround;
      modelBiped.isRiding = mainModel.isRiding;
      modelBiped.isChild = mainModel.isChild;
View Full Code Here

    float limbSwingMod = player.limbSwing - player.limbSwingAmount * (1.0F - partialTick);
    //TPlayerStats stats = TPlayerStats.get(player);
    ArmorExtended armor = ArmorProxyClient.armorExtended; //TODO: Do this for every player, not just the client
    if (armor.inventory[1] != null) {
      Item item = armor.inventory[1].getItem();
      ModelBiped model = item.getArmorModel(player, armor.inventory[1], 4);

      if (item instanceof IAccessoryModel) {
        this.mc.getTextureManager().bindTexture(
            ((IAccessoryModel) item).getWearbleTexture(player, armor.inventory[1], 1));
        model.setLivingAnimations(player, limbSwingMod, limbSwing, partialTick);
        model.render(player, limbSwingMod, limbSwing, pitch, yawRotation - yawOffset,
            bodyRotation, zeropointsixtwofive);
      }
    }

    if (armor.inventory[3] != null) {
      Item item = armor.inventory[3].getItem();
      ModelBiped model = item.getArmorModel(player, armor.inventory[3], 5);

      if (item instanceof IAccessoryModel) {
        this.mc.getTextureManager().bindTexture(
            ((IAccessoryModel) item).getWearbleTexture(player, armor.inventory[1], 1));
        model.setLivingAnimations(player, limbSwingMod, limbSwing, partialTick);
        model.render(player, limbSwingMod, limbSwing, pitch, yawRotation - yawOffset,
            bodyRotation, zeropointsixtwofive);
      }
    }
  }
View Full Code Here

TOP

Related Classes of net.minecraft.client.model.ModelBiped

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.