Search in sources :

Example 16 with ModelBiped

use of net.minecraft.client.model.ModelBiped in project ClaySoldiersMod by SanAndreasP.

the class SoldierModelRenderHandler method renderLilyPants.

private void renderLilyPants(RenderClayMan clayManRender, float partTicks) {
    ModelBiped model = clayManRender.modelBipedMain;
    this.lilypantsBody.rotateAngleX = model.bipedBody.rotateAngleX;
    this.lilypantsBody.rotateAngleY = model.bipedBody.rotateAngleY;
    this.lilypantsBody.rotateAngleZ = model.bipedBody.rotateAngleZ;
    this.lilypantsLeftLeg.rotateAngleX = model.bipedLeftLeg.rotateAngleX;
    this.lilypantsLeftLeg.rotateAngleY = model.bipedLeftLeg.rotateAngleY;
    this.lilypantsLeftLeg.rotateAngleZ = model.bipedLeftLeg.rotateAngleZ;
    this.lilypantsRightLeg.rotateAngleX = model.bipedRightLeg.rotateAngleX;
    this.lilypantsRightLeg.rotateAngleY = model.bipedRightLeg.rotateAngleY;
    this.lilypantsRightLeg.rotateAngleZ = model.bipedRightLeg.rotateAngleZ;
    clayManRender.bindTexture(Textures.CLAYMAN_LILYPANTS);
    this.lilypantsBody.render(partTicks);
    this.lilypantsLeftLeg.render(partTicks);
    this.lilypantsRightLeg.render(partTicks);
}
Also used : ModelBiped(net.minecraft.client.model.ModelBiped)

Example 17 with ModelBiped

use of net.minecraft.client.model.ModelBiped in project ClaySoldiersMod by SanAndreasP.

the class SoldierModelRenderHandler method renderCrown.

private void renderCrown(RenderClayMan clayManRender, float partTicks, boolean isSuper) {
    ModelBiped model = clayManRender.modelBipedMain;
    this.crown.rotateAngleX = model.bipedHead.rotateAngleX;
    this.crown.rotateAngleY = model.bipedHead.rotateAngleY;
    this.crown.rotateAngleZ = model.bipedHead.rotateAngleZ;
    clayManRender.bindTexture(Textures.CLAYMAN_CROWN);
    if (isSuper) {
        GL11.glColor3f(0.39F, 0.82F, 0.742F);
    } else {
        GL11.glColor3f(1.0F, 0.9F, 0.0F);
    }
    this.crown.render(partTicks);
    GL11.glColor3f(1.0F, 1.0F, 1.0F);
}
Also used : ModelBiped(net.minecraft.client.model.ModelBiped)

Example 18 with ModelBiped

use of net.minecraft.client.model.ModelBiped in project BloodMagic by WayofTime.

the class RenderSentientSpecter method setModelVisibilities.

private void setModelVisibilities(EntitySentientSpecter clientPlayer) {
    ModelBiped modelplayer = this.getMainModel();
    ItemStack itemstack = clientPlayer.getHeldItemMainhand();
    ItemStack itemstack1 = clientPlayer.getHeldItemOffhand();
    modelplayer.setVisible(false);
    modelplayer.isSneak = clientPlayer.isSneaking();
    ModelBiped.ArmPose modelbiped$armpose = ModelBiped.ArmPose.EMPTY;
    ModelBiped.ArmPose modelbiped$armpose1 = ModelBiped.ArmPose.EMPTY;
    if (!itemstack.isEmpty()) {
        modelbiped$armpose = ModelBiped.ArmPose.ITEM;
        if (clientPlayer.getItemInUseCount() > 0) {
            EnumAction enumaction = itemstack.getItemUseAction();
            if (enumaction == EnumAction.BLOCK) {
                modelbiped$armpose = ModelBiped.ArmPose.BLOCK;
            } else if (enumaction == EnumAction.BOW) {
                modelbiped$armpose = ModelBiped.ArmPose.BOW_AND_ARROW;
            }
        }
    }
    if (!itemstack1.isEmpty()) {
        modelbiped$armpose1 = ModelBiped.ArmPose.ITEM;
        if (clientPlayer.getItemInUseCount() > 0) {
            EnumAction enumaction1 = itemstack1.getItemUseAction();
            if (enumaction1 == EnumAction.BLOCK) {
                modelbiped$armpose1 = ModelBiped.ArmPose.BLOCK;
            }
        }
    }
    if (clientPlayer.getPrimaryHand() == EnumHandSide.RIGHT) {
        modelplayer.rightArmPose = modelbiped$armpose;
        modelplayer.leftArmPose = modelbiped$armpose1;
    } else {
        modelplayer.rightArmPose = modelbiped$armpose1;
        modelplayer.leftArmPose = modelbiped$armpose;
    }
}
Also used : ModelBiped(net.minecraft.client.model.ModelBiped) ItemStack(net.minecraft.item.ItemStack) EnumAction(net.minecraft.item.EnumAction)

Example 19 with ModelBiped

use of net.minecraft.client.model.ModelBiped in project GregTech by GregTechCE.

the class ArmorLogicRebreather method getArmorModel.

@SideOnly(Side.CLIENT)
private ModelBiped getArmorModel() {
    if (armorModel == null) {
        this.armorModel = new ModelBiped(1.0f, 0.0f, 32, 32);
        this.armorModel.bipedHeadwear.isHidden = true;
        ModelRenderer bipedHead = this.armorModel.bipedHead;
        bipedHead.cubeList.add(new ModelBox(bipedHead, 0, 16, -2.0F, -6.0F, 4.0f, 4, 4, 4, 0.0f));
    }
    return armorModel;
}
Also used : ModelBiped(net.minecraft.client.model.ModelBiped) ModelRenderer(net.minecraft.client.model.ModelRenderer) ModelBox(net.minecraft.client.model.ModelBox) SideOnly(net.minecraftforge.fml.relauncher.SideOnly)

Example 20 with ModelBiped

use of net.minecraft.client.model.ModelBiped in project pnc-repressurized by TeamPneumatic.

the class ClientEventHandler method setRenderHead.

private void setRenderHead(EntityLivingBase entity, boolean setRender) {
    if (entity.getItemStackFromSlot(EntityEquipmentSlot.HEAD).getItem() == Itemss.PNEUMATIC_HELMET && (ConfigHandler.client.useHelmetModel || DateEventHandler.isIronManEvent())) {
        Render renderer = Minecraft.getMinecraft().getRenderManager().getEntityRenderObject(entity);
        if (renderer instanceof RenderBiped) {
            ModelBiped modelBiped = (ModelBiped) ((RenderBiped) renderer).getMainModel();
            modelBiped.bipedHead.showModel = setRender;
        }
    }
}
Also used : ModelBiped(net.minecraft.client.model.ModelBiped) Render(net.minecraft.client.renderer.entity.Render) RenderBiped(net.minecraft.client.renderer.entity.RenderBiped)

Aggregations

ModelBiped (net.minecraft.client.model.ModelBiped)28 ItemStack (net.minecraft.item.ItemStack)7 Item (net.minecraft.item.Item)6 ItemArmor (net.minecraft.item.ItemArmor)5 Color (java.awt.Color)4 SideOnly (cpw.mods.fml.relauncher.SideOnly)3 Render (net.minecraft.client.renderer.entity.Render)3 EntityPlayer (net.minecraft.entity.player.EntityPlayer)3 SubscribeEvent (cpw.mods.fml.common.eventhandler.SubscribeEvent)2 ModelBase (net.minecraft.client.model.ModelBase)2 ModelRenderer (net.minecraft.client.model.ModelRenderer)2 RenderPlayer (net.minecraft.client.renderer.entity.RenderPlayer)2 ItemBlock (net.minecraft.item.ItemBlock)2 SideOnly (net.minecraftforge.fml.relauncher.SideOnly)2 IColouredItem (blusunrize.immersiveengineering.common.items.IEItemInterfaces.IColouredItem)1 IMixinModelBiped (cc.hyperium.mixinsimp.client.model.IMixinModelBiped)1 MinestuckKeyHandler (com.mraof.minestuck.client.settings.MinestuckKeyHandler)1 EntityBigPart (com.mraof.minestuck.entity.EntityBigPart)1 EntityDecoy (com.mraof.minestuck.entity.EntityDecoy)1 EntityPawn (com.mraof.minestuck.entity.carapacian.EntityPawn)1