Massive rework of configs, items and blocks.

I redone where the items/blocsks are stored and how the configs are
handled to clean up it and give space. You can change the config line to
AWWayofTime if you want to keep the compatibility with old configs. Now
you reference the blocks from the ModBlocks and Items from the ModItems.
This commit is contained in:
Fenn 2014-01-17 21:05:38 +00:00
parent 8601e9faff
commit e3644f2d2b
304 changed files with 3941 additions and 5108 deletions

View file

@ -1,5 +1,7 @@
package WayofTime.alchemicalWizardry.common.renderer.block;
import WayofTime.alchemicalWizardry.common.renderer.model.ModelBloodAltar;
import WayofTime.alchemicalWizardry.common.tileEntity.TEAltar;
import net.minecraft.client.renderer.entity.RenderItem;
import net.minecraft.client.renderer.entity.RenderManager;
import net.minecraft.client.renderer.tileentity.TileEntitySpecialRenderer;
@ -8,21 +10,15 @@ import net.minecraft.item.ItemBlock;
import net.minecraft.item.ItemStack;
import net.minecraft.tileentity.TileEntity;
import net.minecraftforge.common.ForgeDirection;
import org.lwjgl.opengl.GL11;
import WayofTime.alchemicalWizardry.common.renderer.model.ModelBloodAltar;
import WayofTime.alchemicalWizardry.common.tileEntity.TEAltar;
public class TEAltarRenderer extends TileEntitySpecialRenderer
{
public class TEAltarRenderer extends TileEntitySpecialRenderer {
private ModelBloodAltar modelBloodAltar = new ModelBloodAltar();
private final RenderItem customRenderItem;
public TEAltarRenderer()
{
customRenderItem = new RenderItem()
{
customRenderItem = new RenderItem() {
@Override
public boolean shouldBob()
{
@ -35,8 +31,8 @@ public class TEAltarRenderer extends TileEntitySpecialRenderer
@Override
public void renderTileEntityAt(TileEntity tileEntity, double d0, double d1, double d2, float f)
{
modelBloodAltar.renderBloodAltar((TEAltar)tileEntity, d0, d1, d2);
modelBloodAltar.renderBloodLevel((TEAltar)tileEntity, d0, d1, d2);
modelBloodAltar.renderBloodAltar((TEAltar) tileEntity, d0, d1, d2);
modelBloodAltar.renderBloodLevel((TEAltar) tileEntity, d0, d1, d2);
if (tileEntity instanceof TEAltar)
{
@ -51,7 +47,7 @@ public class TEAltarRenderer extends TileEntitySpecialRenderer
if (tileAltar.getStackInSlot(0) != null)
{
float scaleFactor = getGhostItemScaleFactor(tileAltar.getStackInSlot(0));
float rotationAngle = (float)(720.0 * (System.currentTimeMillis() & 0x3FFFL) / 0x3FFFL);
float rotationAngle = (float) (720.0 * (System.currentTimeMillis() & 0x3FFFL) / 0x3FFFL);
EntityItem ghostEntityItem = new EntityItem(tileAltar.worldObj);
ghostEntityItem.hoverStart = 0.0F;
ghostEntityItem.setEntityItemStack(tileAltar.getStackInSlot(0));
@ -61,8 +57,7 @@ public class TEAltarRenderer extends TileEntitySpecialRenderer
if (ghostEntityItem.getEntityItem().getItem() instanceof ItemBlock)
{
GL11.glTranslatef((float) d0 + 0.5F, (float) d1 + displacement + 0.7F, (float) d2 + 0.5F);
}
else
} else
{
GL11.glTranslatef((float) d0 + 0.5F, (float) d1 + displacement + 0.6F, (float) d2 + 0.5F);
}
@ -107,8 +102,7 @@ public class TEAltarRenderer extends TileEntitySpecialRenderer
default:
return 0.90F;
}
}
else
} else
{
switch (customRenderItem.getMiniItemCount(itemStack))
{
@ -187,8 +181,7 @@ public class TEAltarRenderer extends TileEntitySpecialRenderer
return;
}
}
}
else
} else
{
switch (forgeDirection)
{