Textured Slanted Model

well mostly, the Up slant needs a seperate texture unless someone can
think of a way to use the current without rotating the model alot.
This commit is contained in:
Rseifert 2013-01-10 01:22:26 -05:00
parent d62c13e675
commit 370681e042
29 changed files with 37 additions and 21 deletions

Binary file not shown.

Before

Width:  |  Height:  |  Size: 839 B

BIN
models/Thumbs.db Normal file

Binary file not shown.

Binary file not shown.

Binary file not shown.

After

Width:  |  Height:  |  Size: 1,018 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 968 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 835 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 1,017 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1,020 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 936 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1,020 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 1,012 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 1,009 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 1,014 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 1,005 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 1,017 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 1,018 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 1,011 B

View file

@ -31,40 +31,56 @@ public class RenderConveyorBelt extends TileEntitySpecialRenderer
int frame = tileEntity.getAnimationFrame();
switch (face)
{
case 2:
GL11.glRotatef(0f, 0f, 1f, 0f);
break;
case 3:
GL11.glRotatef(180f, 0f, 1f, 0f);
break;
case 4:
GL11.glRotatef(-90f, 0f, 1f, 0f);
break;
case 5:
GL11.glRotatef(90f, 0f, 1f, 0f);
break;
}
if (slantType != null && slantType != SlantType.NONE)
{
this.bindTextureByName(AssemblyLine.TEXTURE_PATH + "Grey64.png");
if (slantType == SlantType.UP)
switch (face)
{
GL11.glRotatef(180f, 0f, 1f, 0f);
case 2:
GL11.glRotatef(180f, 0f, 1f, 0f);
break;
case 3:
GL11.glRotatef(0f, 0f, 1f, 0f);
break;
case 4:
GL11.glRotatef(90f, 0f, 1f, 0f);
break;
case 5:
GL11.glRotatef(-90f, 0f, 1f, 0f);
break;
}
if (slantType == SlantType.UP)
{
this.bindTextureByName(AssemblyLine.TEXTURE_PATH + "slantedbelt/Upframe0.png");
//GL11.glRotatef(-90f, 1f, 0f, 0f);
model2.render(0.0625F);
}
else if (slantType == SlantType.DOWN)
{
this.bindTextureByName(AssemblyLine.TEXTURE_PATH + "slantedbelt/frame"+frame+".png");
GL11.glRotatef(180f, 0f, 1f, 0f);
model2.render(0.0625F);
}
}
else
{
switch (face)
{
case 2:
GL11.glRotatef(0f, 0f, 1f, 0f);
break;
case 3:
GL11.glRotatef(180f, 0f, 1f, 0f);
break;
case 4:
GL11.glRotatef(-90f, 0f, 1f, 0f);
break;
case 5:
GL11.glRotatef(90f, 0f, 1f, 0f);
break;
}
this.bindTextureByName(AssemblyLine.TEXTURE_PATH + "belt/frame" + frame + ".png");
model.render(0.0625F, (float) Math.toRadians(tileEntity.wheelRotation), tileEntity.getIsLastBelt(), tileEntity.getIsFirstBelt(), false);