Mess with some translations on the Runic Altar render.

This commit is contained in:
Vasco Lavos committed 2014-02-02 22:28:19 +00:00
1 parent 62c0e66c7c
commit a39ec7bca8
2 files changed
+8 -2

No files matched your search

@@ -51,9 +51,9 @@ public class RenderTileRuneAltar extends TileEntitySpecialRenderer {
for(int i = 0; i < altar.getSizeInventory(); i++) {
GL11.glPushMatrix();
GL11.glScalef(0.5F, 0.5F, 0.5F);
GL11.glTranslatef(1F, 1.5F, 1F);
GL11.glTranslatef(1F, 2.5F, 1F);
GL11.glRotatef(altar.angles[i], 0F, 1F, 0F);
GL11.glTranslatef(1.25F, 0F, 0.5F);
GL11.glTranslatef(2.25F, 0F, 0.5F);
GL11.glRotatef(90F, 0F, 1F, 0F);
GL11.glTranslated(0D, 0.1 * Math.sin((double) (tileentity.worldObj.getTotalWorldTime() + i * 10) / 5D), 0F);
ItemStack stack = altar.getStackInSlot(i);
@@ -19,6 +19,7 @@ import vazkii.botania.common.lib.LibBlockNames;
public class TileRuneAltar extends TileSimpleInventory implements ISidedInventory {
public float[] angles = new float[getSizeInventory()];
boolean firstTick = true;
public void addItem(EntityPlayer player, ItemStack stack) {
for(int i = 0; i < getSizeInventory(); i++)
@@ -41,6 +42,11 @@ public class TileRuneAltar extends TileSimpleInventory implements ISidedInventor
public void updateEntity() {
super.updateEntity();
if(firstTick) {
updateRotationAngles();
firstTick = false;
}
for(int i = 0; i < angles.length; i++)
angles[i]++;
}