package ru.tiaryy.models;
import org.lwjgl.opengl.GL11;
import net.minecraft.client.model.ModelBiped;
import net.minecraft.client.model.ModelRenderer;
import net.minecraft.entity.Entity;
public class ModelOtwelnik
extends ModelBiped
{
public ModelRenderer Shape1;
public ModelRenderer Shape2;
public ModelRenderer prawayanoga3;
public ModelRenderer lewayanoga3;
public ModelRenderer prawayaruka4;
public ModelRenderer lewayaruka4;
public ModelRenderer lewayaruka3;
public ModelRenderer prawayaruka3;
public ModelRenderer prawayaruka2;
public ModelRenderer lewayaruka2;
public ModelRenderer Shape6;
public ModelRenderer Shape5;
public ModelRenderer prawayaruka1;
public ModelRenderer lewayaruka1;
public ModelRenderer Shape14;
public ModelRenderer Shape15;
public ModelRenderer Shape16;
public ModelRenderer Shape17;
public ModelRenderer prawayanoga2;
public ModelRenderer lewaiyanoga2;
public ModelRenderer prawayanoga1;
public ModelRenderer lewaiyanoga1;
//oбезательная хрень,(мoдели фиксация на груди)
ModelRenderer bodyLock;
ModelRenderer armLockRight;
ModelRenderer armLockLeft;
ModelRenderer legLockLeft;
ModelRenderer legLockRight;
public ModelRenderer legLockRightLower;
public ModelRenderer legLockLeftLower;
private Object bipedLeftLegLower;
private Object bipedRightLegLower;
public ModelOtwelnik (float f)
{
textureWidth = 256;
textureHeight = 128;
float yOffset = 1.6F;
Shape1 = new ModelRenderer(this, 1, 1);
Shape1.addBox(0F, 0F, 0F, 8, 12, 0);
Shape1.setRotationPoint(-4F, -2F, 2.01F);
Shape1.setTextureSize(64, 32);
Shape1.mirror = true;
setRotation(Shape1, 0F, 0F, 0F);
Shape2 = new ModelRenderer(this, 25, 1);
Shape2.addBox(0F, 0F, 0F, 8, 12, 0);
Shape2.setRotationPoint(-4F, -2F, -2.01F);
Shape2.setTextureSize(64, 32);
Shape2.mirror = true;
setRotation(Shape2, 0F, 0F, 0F);
prawayanoga3 = new ModelRenderer(this, 49, 1);
prawayanoga3.addBox(-4F, 0F, 0F, 4, 10, 0);
prawayanoga3.setRotationPoint(0F, 10F, -2.01F);
prawayanoga3.setTextureSize(64, 32);
prawayanoga3.mirror = true;
setRotation(prawayanoga3, 0F, 0F, 0F);
lewayanoga3 = new ModelRenderer(this, 65, 1);
lewayanoga3.addBox(0F, 0F, 0F, 4, 10, 0);
lewayanoga3.setRotationPoint(0F, 10F, -2.01F);
lewayanoga3.setTextureSize(64, 32);
lewayanoga3.mirror = true;
setRotation(lewayanoga3, 0F, 0F, 0F);
prawayaruka4 = new ModelRenderer(this, 81, 1);
prawayaruka4.addBox(-4F, 0F, 0F, 4, 10, 0);
prawayaruka4.setRotationPoint(-4F, -2F, -2.01F);
prawayaruka4.setTextureSize(64, 32);
prawayaruka4.mirror = true;
setRotation(prawayaruka4, 0F, 0F, 0F);
lewayaruka4 = new ModelRenderer(this, 97, 1);
lewayaruka4.addBox(0F, 0F, 0F, 4, 10, 0);
lewayaruka4.setRotationPoint(4F, -2F, -2.01F);
lewayaruka4.setTextureSize(64, 32);
lewayaruka4.mirror = true;
setRotation(lewayaruka4, 0F, 0F, 0F);
lewayaruka3 = new ModelRenderer(this, 113, 1);
lewayaruka3.addBox(0F, 0F, 4F, 4, 10, 0);
lewayaruka3.setRotationPoint(4F, -2F, -1.99F);
lewayaruka3.setTextureSize(64, 32);
lewayaruka3.mirror = true;
setRotation(lewayaruka3, 0F, 0F, 0F);
prawayaruka3 = new ModelRenderer(this, 129, 1);
prawayaruka3.addBox(-4F, 0F, 4F, 4, 10, 0);
prawayaruka3.setRotationPoint(-4F, -2F, -1.99F);
prawayaruka3.setTextureSize(64, 32);
prawayaruka3.mirror = true;
setRotation(prawayaruka3, 0F, 0F, 0F);
prawayaruka2 = new ModelRenderer(this, 145, 1);
prawayaruka2.addBox(-4F, 0F, 0F, 0, 10, 4);
prawayaruka2.setRotationPoint(-4.01F, -2F, -2F);
prawayaruka2.setTextureSize(64, 32);
prawayaruka2.mirror = true;
setRotation(prawayaruka2, 0F, 0F, 0F);
lewayaruka2 = new ModelRenderer(this, 161, 1);
lewayaruka2.addBox(4F, 0F, 0F, 0, 10, 4);
lewayaruka2.setRotationPoint(4.01F, -2F, -2F);
lewayaruka2.setTextureSize(64, 32);
lewayaruka2.mirror = true;
setRotation(lewayaruka2, 0F, 0F, 0F);
Shape6 = new ModelRenderer(this, 177, 1);
Shape6.addBox(0F, 0F, 0F, 0, 12, 4);
Shape6.setRotationPoint(4.01F, -2F, -2F);
Shape6.setTextureSize(64, 32);
Shape6.mirror = true;
setRotation(Shape6, 0F, 0F, 0F);
Shape5 = new ModelRenderer(this, 193, 1);
Shape5.addBox(0F, 0F, 0F, 0, 12, 4);
Shape5.setRotationPoint(-4.01F, -2F, -2F);
Shape5.setTextureSize(64, 32);
Shape5.mirror = true;
setRotation(Shape5, 0F, 0F, 0F);
prawayaruka1 = new ModelRenderer(this, 209, 1);
prawayaruka1.addBox(-4F, 0F, 0F, 4, 0, 4);
prawayaruka1.setRotationPoint(-4F, -2.01F, -2F);
prawayaruka1.setTextureSize(64, 32);
prawayaruka1.mirror = true;
setRotation(prawayaruka1, 0F, 0F, 0F);
lewayaruka1 = new ModelRenderer(this, 225, 1);
lewayaruka1.addBox(0F, 0F, 0F, 4, 0, 4);
lewayaruka1.setRotationPoint(4F, -2.01F, -2F);
lewayaruka1.setTextureSize(64, 32);
lewayaruka1.mirror = true;
setRotation(lewayaruka1, 0F, 0F, 0F);
Shape14 = new ModelRenderer(this, 233, 1);
Shape14.addBox(0F, 0F, 0F, 2, 0, 8);
Shape14.setRotationPoint(4F, -2.01F, -4F);
Shape14.setTextureSize(64, 32);
Shape14.mirror = true;
setRotation(Shape14, 0F, 0F, -1.32645F);
Shape15 = new ModelRenderer(this, 209, 9);
Shape15.addBox(0F, 0F, 0F, 2, 0, 8);
Shape15.setRotationPoint(-4F, -2.01F, -4F);
Shape15.setTextureSize(64, 32);
Shape15.mirror = true;
setRotation(Shape15, 0F, 0F, 4.39823F);
Shape16 = new ModelRenderer(this, 25, 17);
Shape16.addBox(0F, 0F, 0F, 14, 4, 4);
Shape16.setRotationPoint(-7F, 6F, 2F);
Shape16.setTextureSize(64, 32);
Shape16.mirror = true;
setRotation(Shape16, 0F, 0F, 0F);
Shape17 = new ModelRenderer(this, 65, 17);
Shape17.addBox(0F, 0F, 0F, 15, 3, 3);
Shape17.setRotationPoint(-7.5F, 6.5F, 2.5F);
Shape17.setTextureSize(64, 32);
Shape17.mirror = true;
setRotation(Shape17, 0F, 0F, 0F);
prawayanoga2 = new ModelRenderer(this, 1, 13);
prawayanoga2.addBox(-4F, 0F, 4F, 4, 10, 0);
prawayanoga2.setRotationPoint(0F, 10F, -1.99F);
prawayanoga2.setTextureSize(64, 32);
prawayanoga2.mirror = true;
setRotation(prawayanoga2, 0F, 0F, 0F);
lewaiyanoga2 = new ModelRenderer(this, 1, 13);
lewaiyanoga2.addBox(0F, 0F, 4F, 4, 10, 0);
lewaiyanoga2.setRotationPoint(0F, 10F, -1.99F);
lewaiyanoga2.setTextureSize(64, 32);
lewaiyanoga2.mirror = true;
setRotation(lewaiyanoga2, 0F, 0F, 0F);
prawayanoga1 = new ModelRenderer(this, 0, 9);
prawayanoga1.addBox(-4F, 0F, 0F, 0, 10, 4);
prawayanoga1.setRotationPoint(-0.01F, 10F, -2F);
prawayanoga1.setTextureSize(64, 32);
prawayanoga1.mirror = true;
setRotation(prawayanoga1, 0F, 0F, 0F);
lewaiyanoga1 = new ModelRenderer(this, 0, 9);
lewaiyanoga1.addBox(4F, 0F, 0F, 0, 10, 4);
lewaiyanoga1.setRotationPoint(0.01F, 10F, -2F);
lewaiyanoga1.setTextureSize(64, 32);
lewaiyanoga1.mirror = true;
setRotation(lewaiyanoga1, 0F, 0F, 0F);
bodyLock = new ModelRenderer(this, 1, 1);
bodyLock.addBox(0F, 0F, 0F, 0, 0, 0);
bodyLock.setRotationPoint(0F, 0F, 0F);
armLockLeft = new ModelRenderer(this, 1, 1);
armLockLeft.addBox(0F, 0F, 0F, 0, 0, 0);
armLockLeft.setRotationPoint(0F, 0F, 0F);
armLockRight = new ModelRenderer(this, 1, 1);
armLockRight.addBox(0F, 0F, 0F, 0, 0, 0);
armLockRight.setRotationPoint(0F, 0F, 0F);
legLockLeftLower = new ModelRenderer(this, 1, 1);
legLockLeftLower.addBox(0F, 0F, 0F, 0, 0, 0);
legLockLeftLower.setRotationPoint(0F, 0F, 0F);
legLockRight = new ModelRenderer(this, 1, 1);
legLockRight.addBox(0F, 0F, 0F, 0, 0, 0);
legLockRight.setRotationPoint(0F, 0F, 0F);
legLockRightLower.addChild(prawayanoga1);
legLockRightLower.addChild(prawayanoga2);
armLockRight.addChild(prawayaruka1);
armLockRight.addChild(prawayaruka2);
armLockRight.addChild(prawayaruka3);
armLockRight.addChild(prawayaruka4);
armLockLeft.addChild(lewayaruka1);
armLockLeft.addChild(lewayaruka2);
armLockLeft.addChild(lewayaruka3);
armLockLeft.addChild(lewayaruka4);
legLockLeftLower.addChild(lewaiyanoga1);
legLockLeftLower.addChild(lewaiyanoga2);
bodyLock.addChild(Shape2);
bodyLock.addChild(Shape5);
bodyLock.addChild(Shape6);
bodyLock.addChild(Shape14);
bodyLock.addChild(Shape15);
bodyLock.addChild(Shape16);
bodyLock.addChild(Shape17);
}
public void render(Entity entity, float f, float f1, float f2, float f3, float f4, float f5)
{
setRotationAngles(f, f1, f2, f3, f4, f5, entity);
trackPart(this.bipedLeftLegLower, this.legLockLeftLower);
trackPart(this.bipedRightLegLower, this.legLockRightLower);
renderWithLock(this.bipedLeftArm, armLockLeft, f5);
renderWithLock(this.bipedRightArm, armLockRight, f5);
renderWithLock(this.bipedBody, bodyLock, f5);
renderWithLock(this.bipedLeftLeg, legLockRight, f5);
renderWithLock(this.bipedRightLeg, legLockRight, f5);
}
private void trackPart(Object bipedLeftLegLower2, ModelRenderer legLockLeftLower2) {
// TODO Auto-generated method stub
}
private void renderWithLock(ModelRenderer bipedBody, ModelRenderer lockblock, float f5) {
double scale = 1.1D;
GL11.glPushMatrix();
setRotation(lockblock, bipedBody.rotateAngleX, bipedBody.rotateAngleY, bipedBody.rotateAngleZ);
lockblock.setRotationPoint(0,0,0);
GL11.glTranslatef(bipedBody.rotationPointX / 16, bipedBody.rotationPointY / 16, bipedBody.rotationPointZ / 16);
GL11.glScaled(scale, scale, scale);
lockblock.render(f5);
GL11.glPopMatrix();
}
private void setRotation(ModelRenderer model, float x, float y, float z)
{
model.rotateAngleX = x;
model.rotateAngleY = y;
model.rotateAngleZ = z;
}
public void setRotationAngles(float f, float f1, float f2, float f3, float f4, float f5, Entity entity)
{
super.setRotationAngles(f, f1, f2, f3, f4, f5, entity);
}
}