// Date: 9/25/2012 4:29:17 PM
// Template version 1.1
// Java generated by Techne
// Keep in mind that you still need to fill in some blanks
// - ZeuX

package resonantinduction.old.client.model;

import net.minecraft.client.model.ModelBase;
import net.minecraft.client.model.ModelRenderer;
import cpw.mods.fml.relauncher.Side;
import cpw.mods.fml.relauncher.SideOnly;

@SideOnly(Side.CLIENT)
public class ModelGearRod extends ModelBase
{
	// fields
	ModelRenderer Rod;
	ModelRenderer front;
	ModelRenderer back;
	ModelRenderer f2;
	ModelRenderer b2;
	ModelRenderer b3;
	ModelRenderer b4;
	ModelRenderer b1;
	ModelRenderer f1;
	ModelRenderer f4;
	ModelRenderer f3;
	ModelRenderer Rod2;

	public ModelGearRod()
	{
		textureWidth = 64;
		textureHeight = 32;

		Rod = new ModelRenderer(this, 0, 0);
		Rod.addBox(-1.5F, -1.5F, 0F, 3, 3, 12);
		Rod.setRotationPoint(0F, 16F, -6F);
		Rod.setTextureSize(64, 32);
		Rod.mirror = true;
		setRotation(Rod, 0F, 0F, 0F);
		front = new ModelRenderer(this, 35, 0);
		front.addBox(-2F, -2F, -2F, 4, 4, 2);
		front.setRotationPoint(0F, 16F, -6F);
		front.setTextureSize(64, 32);
		front.mirror = true;
		setRotation(front, 0F, 0F, 0F);
		back = new ModelRenderer(this, 35, 0);
		back.addBox(-2F, -2F, 0F, 4, 4, 2);
		back.setRotationPoint(0F, 16F, 6F);
		back.setTextureSize(64, 32);
		back.mirror = true;
		setRotation(back, 0F, 0F, 0.7853982F);
		f2 = new ModelRenderer(this, 0, 17);
		f2.addBox(0F, 0F, 0F, 1, 1, 2);
		f2.setRotationPoint(1F, 17F, -10F);
		f2.setTextureSize(64, 32);
		f2.mirror = true;
		setRotation(f2, 0F, 0F, 0F);
		b2 = new ModelRenderer(this, 0, 17);
		b2.addBox(-0.5F, -0.5F, 0F, 1, 1, 2);
		b2.setRotationPoint(0F, 18F, 8F);
		b2.setTextureSize(64, 32);
		b2.mirror = true;
		setRotation(b2, 0F, 0F, 0.7853982F);
		b3 = new ModelRenderer(this, 0, 17);
		b3.addBox(-0.5F, -0.5F, 0F, 1, 1, 2);
		b3.setRotationPoint(-2F, 16F, 8F);
		b3.setTextureSize(64, 32);
		b3.mirror = true;
		setRotation(b3, 0F, 0F, 0.7853982F);
		b4 = new ModelRenderer(this, 0, 17);
		b4.addBox(-0.5F, -0.5F, 0F, 1, 1, 2);
		b4.setRotationPoint(2F, 16F, 8F);
		b4.setTextureSize(64, 32);
		b4.mirror = true;
		setRotation(b4, 0F, 0F, 0.7853982F);
		b1 = new ModelRenderer(this, 0, 17);
		b1.addBox(-0.5F, -0.5F, 0F, 1, 1, 2);
		b1.setRotationPoint(0F, 14F, 8F);
		b1.setTextureSize(64, 32);
		b1.mirror = true;
		setRotation(b1, 0F, 0F, 0.7853982F);
		f1 = new ModelRenderer(this, 0, 17);
		f1.addBox(0F, 0F, 0F, 1, 1, 2);
		f1.setRotationPoint(1F, 14F, -10F);
		f1.setTextureSize(64, 32);
		f1.mirror = true;
		setRotation(f1, 0F, 0F, 0F);
		f4 = new ModelRenderer(this, 0, 17);
		f4.addBox(0F, 0F, 0F, 1, 1, 2);
		f4.setRotationPoint(-2F, 17F, -10F);
		f4.setTextureSize(64, 32);
		f4.mirror = true;
		setRotation(f4, 0F, 0F, 0F);
		f3 = new ModelRenderer(this, 0, 17);
		f3.addBox(0F, 0F, 0F, 1, 1, 2);
		f3.setRotationPoint(-2F, 14F, -10F);
		f3.setTextureSize(64, 32);
		f3.mirror = true;
		setRotation(f3, 0F, 0F, 0F);
		Rod2 = new ModelRenderer(this, 0, 0);
		Rod2.addBox(-1.5F, -1.5F, 0F, 3, 3, 12);
		Rod2.setRotationPoint(0F, 16F, -6F);
		Rod2.setTextureSize(64, 32);
		Rod2.mirror = true;
		setRotation(Rod2, 0F, 0F, 0.7853982F);
	}

	public void render(float f5, int pos)
	{

		// Rod.rotateAngleZ = 45 * tileEntity;
		Rod2.rotateAngleZ = Rod.rotateAngleZ + 45;

		Rod.render(f5);
		Rod2.render(f5);
		// TODO add rotation to rods
		front.render(f5);
		back.render(f5);
		f2.render(f5);
		b2.render(f5);
		b3.render(f5);
		b4.render(f5);
		b1.render(f5);
		f1.render(f5);
		f4.render(f5);
		f3.render(f5);

	}

	private void setRotation(ModelRenderer model, float x, float y, float z)
	{
		model.rotateAngleX = x;
		model.rotateAngleY = y;
		model.rotateAngleZ = z;
	}

}
