mirror of
https://github.com/GTNewHorizons/Electro-Magic-Tools.git
synced 2026-11-18 19:29:29 +00:00
cleanup
This commit is contained in:
1 parent
0b8b56a74b
commit
3aef354b3a
16 files changed
+325
-269
No files matched your search
@@ -14,13 +14,14 @@ public class RenderLaser extends Render {
|
||||
|
||||
private static final ResourceLocation laserTexture = new ResourceLocation(ModInformation.texturePath, "textures/models/lasermodel.png");
|
||||
|
||||
@Override
|
||||
public void doRender(Entity entityLaser, double x, double y, double z, float par8, float par9) {
|
||||
this.bindEntityTexture(entityLaser);
|
||||
GL11.glPushMatrix();
|
||||
GL11.glTranslated(x, y, z);
|
||||
GL11.glRotatef(entityLaser.prevRotationYaw + (entityLaser.rotationYaw - entityLaser.prevRotationYaw) * par9 - 90, 0, 1, 0);
|
||||
GL11.glRotatef(entityLaser.prevRotationPitch + (entityLaser.rotationPitch - entityLaser.prevRotationPitch) * par9, 0, 0, 1);
|
||||
Tessellator tessellator = Tessellator.instance;
|
||||
Tessellator tess = Tessellator.instance;
|
||||
byte b0 = 0;
|
||||
float f2 = 0.4f;
|
||||
float f3 = 0.7f;
|
||||
@@ -38,22 +39,21 @@ public class RenderLaser extends Render {
|
||||
for (int i = 0; i < 4; ++i) {
|
||||
GL11.glRotatef(90, 1, 0, 0);
|
||||
GL11.glNormal3f(0, 0, f10);
|
||||
tessellator.startDrawingQuads();
|
||||
tessellator.addVertexWithUV(-8, 0, 0, f2, f4);
|
||||
tessellator.addVertexWithUV(8, 0, 0, f3, f4);
|
||||
tessellator.addVertexWithUV(8, 4, 0, f3, f5);
|
||||
tessellator.addVertexWithUV(-8, 4, 0, f2, f5);
|
||||
tessellator.draw();
|
||||
tess.startDrawingQuads();
|
||||
tess.addVertexWithUV(-8, 0, 0, f2, f4);
|
||||
tess.addVertexWithUV(8, 0, 0, f3, f4);
|
||||
tess.addVertexWithUV(8, 4, 0, f3, f5);
|
||||
tess.addVertexWithUV(-8, 4, 0, f2, f5);
|
||||
tess.draw();
|
||||
|
||||
tessellator.startDrawingQuads();
|
||||
tessellator.addVertexWithUV(8, 0, 0, f2, f4);
|
||||
tessellator.addVertexWithUV(-8, 0, 0, f3, f4);
|
||||
tessellator.addVertexWithUV(-8, 4, 0, f3, f5);
|
||||
tessellator.addVertexWithUV(8, 4, 0, f2, f5);
|
||||
tessellator.draw();
|
||||
tess.startDrawingQuads();
|
||||
tess.addVertexWithUV(8, 0, 0, f2, f4);
|
||||
tess.addVertexWithUV(-8, 0, 0, f3, f4);
|
||||
tess.addVertexWithUV(-8, 4, 0, f3, f5);
|
||||
tess.addVertexWithUV(8, 4, 0, f2, f5);
|
||||
tess.draw();
|
||||
}
|
||||
GL11.glPopAttrib();
|
||||
|
||||
GL11.glDisable(GL12.GL_RESCALE_NORMAL);
|
||||
GL11.glPopMatrix();
|
||||
}
|
||||
@@ -62,7 +62,8 @@ public class RenderLaser extends Render {
|
||||
return laserTexture;
|
||||
}
|
||||
|
||||
protected ResourceLocation getEntityTexture(Entity par1Entity) {
|
||||
return this.getArrowTextures((EntityLaser) par1Entity);
|
||||
@Override
|
||||
protected ResourceLocation getEntityTexture(Entity entity) {
|
||||
return this.getArrowTextures((EntityLaser) entity);
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user