Fixed battery render
This commit is contained in:
parent
e3d043f5e5
commit
f51b0c67b7
1 changed files with 9 additions and 17 deletions
|
@ -5,28 +5,16 @@ package resonantinduction.battery;
|
|||
|
||||
import java.util.Random;
|
||||
|
||||
import net.minecraft.block.Block;
|
||||
import net.minecraft.client.Minecraft;
|
||||
import net.minecraft.client.renderer.ItemRenderer;
|
||||
import net.minecraft.client.renderer.Tessellator;
|
||||
import net.minecraft.client.renderer.entity.RenderManager;
|
||||
import net.minecraft.client.renderer.texture.TextureManager;
|
||||
import net.minecraft.client.renderer.texture.TextureMap;
|
||||
import net.minecraft.client.renderer.tileentity.TileEntitySpecialRenderer;
|
||||
import net.minecraft.entity.item.EntityItem;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.tileentity.TileEntity;
|
||||
import net.minecraft.util.Icon;
|
||||
import net.minecraft.util.ResourceLocation;
|
||||
import net.minecraftforge.client.model.AdvancedModelLoader;
|
||||
import net.minecraftforge.client.model.IModelCustom;
|
||||
import net.minecraftforge.common.ForgeDirection;
|
||||
|
||||
import org.lwjgl.opengl.GL11;
|
||||
|
||||
import resonantinduction.ResonantInduction;
|
||||
import resonantinduction.model.ModelBattery;
|
||||
import universalelectricity.api.vector.Vector3;
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
|
||||
|
@ -45,8 +33,6 @@ public class RenderBattery extends TileEntitySpecialRenderer
|
|||
private Random random = new Random();
|
||||
protected RenderManager renderManager;
|
||||
|
||||
//public static final IModelCustom batteryModel = AdvancedModelLoader.loadModel(ResonantInduction.MODEL_DIRECTORY + "battery.tcn");
|
||||
|
||||
@Override
|
||||
public void renderTileEntityAt(TileEntity t, double x, double y, double z, float f)
|
||||
{
|
||||
|
@ -54,10 +40,16 @@ public class RenderBattery extends TileEntitySpecialRenderer
|
|||
GL11.glTranslated(x + 0.5, y + 1.5, z + 0.5);
|
||||
GL11.glRotatef(180F, 0.0F, 0.0F, 1.0F);
|
||||
|
||||
if (((TileBattery) t).structure.isMultiblock)
|
||||
{
|
||||
this.bindTexture(TEXTURE_MULTI);
|
||||
}
|
||||
else
|
||||
{
|
||||
this.bindTexture(TEXTURE);
|
||||
}
|
||||
|
||||
MODEL.render(0.0625f);
|
||||
/*
|
||||
* GL11.glScalef(0.0625f, 0.0625f, 0.0625f); batteryModel.renderAll();
|
||||
*/
|
||||
GL11.glPopMatrix();
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue