Fixed multimeter gui

This commit is contained in:
Calclavia 2013-08-03 19:46:13 -04:00
parent 2586b061e3
commit 8e88109eac
3 changed files with 8 additions and 1 deletions

View file

@ -14,7 +14,7 @@ import net.minecraft.inventory.Slot;
*/
public class ContainerMultimeter extends Container
{
private final int yDisplacement = 0;
private final int yDisplacement = 51;
public ContainerMultimeter(InventoryPlayer inventoryPlayer, TileEntityMultimeter tileEntity)
{

View file

@ -32,6 +32,7 @@ public class GuiMultimeter extends GuiContainer
{
super(new ContainerMultimeter(inventoryPlayer, tileEntity));
this.tileEntity = tileEntity;
this.ySize = 217;
}
@Override
@ -39,6 +40,7 @@ public class GuiMultimeter extends GuiContainer
{
String s = this.tileEntity.getBlockType().getLocalizedName();
this.fontRenderer.drawString(s, this.xSize / 2 - this.fontRenderer.getStringWidth(s) / 2, 6, 4210752);
this.fontRenderer.drawString("Energy: " + this.tileEntity.getDetectedEnergy(), 9, 15, 4210752);
}
@Override

View file

@ -11,6 +11,11 @@ import resonantinduction.base.TileEntityBase;
*/
public class TileEntityMultimeter extends TileEntityBase
{
public float getDetectedEnergy()
{
return 0;
}
public boolean canUpdate()
{
return false;