package net.minecraft.src;

public class EntityFireworkOverlayFX extends EntityFX {
	protected EntityFireworkOverlayFX(World var1, double var2, double var4, double var6) {
		super(var1, var2, var4, var6);
		this.particleMaxAge = 4;
	}

	public void renderParticle(Tessellator var1, float var2, float var3, float var4, float var5, float var6, float var7) {
		float var8 = 0.25F;
		float var9 = var8 + 0.25F;
		float var10 = 2.0F / 16.0F;
		float var11 = var10 + 0.25F;
		float var12 = 7.1F * MathHelper.sin(((float)this.particleAge + var2 - 1.0F) * 0.25F * (float)Math.PI);
		this.particleAlpha = 0.6F - ((float)this.particleAge + var2 - 1.0F) * 0.25F * 0.5F;
		float var13 = (float)(this.prevPosX + (this.posX - this.prevPosX) * (double)var2 - interpPosX);
		float var14 = (float)(this.prevPosY + (this.posY - this.prevPosY) * (double)var2 - interpPosY);
		float var15 = (float)(this.prevPosZ + (this.posZ - this.prevPosZ) * (double)var2 - interpPosZ);
		var1.setColorRGBA_F(this.particleRed, this.particleGreen, this.particleBlue, this.particleAlpha);
		var1.addVertexWithUV((double)(var13 - var3 * var12 - var6 * var12), (double)(var14 - var4 * var12), (double)(var15 - var5 * var12 - var7 * var12), (double)var9, (double)var11);
		var1.addVertexWithUV((double)(var13 - var3 * var12 + var6 * var12), (double)(var14 + var4 * var12), (double)(var15 - var5 * var12 + var7 * var12), (double)var9, (double)var10);
		var1.addVertexWithUV((double)(var13 + var3 * var12 + var6 * var12), (double)(var14 + var4 * var12), (double)(var15 + var5 * var12 + var7 * var12), (double)var8, (double)var10);
		var1.addVertexWithUV((double)(var13 + var3 * var12 - var6 * var12), (double)(var14 - var4 * var12), (double)(var15 + var5 * var12 - var7 * var12), (double)var8, (double)var11);
	}
}
