mirror of
https://github.com/Ellpeck/ActuallyAdditions.git
synced 2024-11-22 23:28:35 +01:00
Derping is my speciality!
Fixed everything for 0.0.6.3!
This commit is contained in:
parent
1e5c26879e
commit
8867c358b4
10 changed files with 18 additions and 28 deletions
|
@ -13,7 +13,6 @@ import net.minecraft.inventory.ICrafting;
|
||||||
import net.minecraft.inventory.Slot;
|
import net.minecraft.inventory.Slot;
|
||||||
import net.minecraft.item.ItemStack;
|
import net.minecraft.item.ItemStack;
|
||||||
import net.minecraft.item.crafting.FurnaceRecipes;
|
import net.minecraft.item.crafting.FurnaceRecipes;
|
||||||
import net.minecraftforge.common.util.ForgeDirection;
|
|
||||||
|
|
||||||
@InventoryContainer
|
@InventoryContainer
|
||||||
public class ContainerFurnaceDouble extends Container{
|
public class ContainerFurnaceDouble extends Container{
|
||||||
|
@ -49,7 +48,7 @@ public class ContainerFurnaceDouble extends Container{
|
||||||
iCraft.sendProgressBarUpdate(this, 0, this.tileFurnace.firstSmeltTime);
|
iCraft.sendProgressBarUpdate(this, 0, this.tileFurnace.firstSmeltTime);
|
||||||
iCraft.sendProgressBarUpdate(this, 1, this.tileFurnace.secondSmeltTime);
|
iCraft.sendProgressBarUpdate(this, 1, this.tileFurnace.secondSmeltTime);
|
||||||
iCraft.sendProgressBarUpdate(this, 2, this.tileFurnace.maxBurnTime);
|
iCraft.sendProgressBarUpdate(this, 2, this.tileFurnace.maxBurnTime);
|
||||||
iCraft.sendProgressBarUpdate(this, 3, this.tileFurnace.getEnergyStored(ForgeDirection.UNKNOWN));
|
iCraft.sendProgressBarUpdate(this, 3, this.tileFurnace.storage.getEnergyStored());
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
@ -61,13 +60,13 @@ public class ContainerFurnaceDouble extends Container{
|
||||||
if(this.lastFirstCrushTime != this.tileFurnace.firstSmeltTime) iCraft.sendProgressBarUpdate(this, 0, this.tileFurnace.firstSmeltTime);
|
if(this.lastFirstCrushTime != this.tileFurnace.firstSmeltTime) iCraft.sendProgressBarUpdate(this, 0, this.tileFurnace.firstSmeltTime);
|
||||||
if(this.lastSecondCrushTime != this.tileFurnace.secondSmeltTime) iCraft.sendProgressBarUpdate(this, 1, this.tileFurnace.secondSmeltTime);
|
if(this.lastSecondCrushTime != this.tileFurnace.secondSmeltTime) iCraft.sendProgressBarUpdate(this, 1, this.tileFurnace.secondSmeltTime);
|
||||||
if(this.lastBurnTime != this.tileFurnace.maxBurnTime) iCraft.sendProgressBarUpdate(this, 2, this.tileFurnace.maxBurnTime);
|
if(this.lastBurnTime != this.tileFurnace.maxBurnTime) iCraft.sendProgressBarUpdate(this, 2, this.tileFurnace.maxBurnTime);
|
||||||
if(this.lastEnergy != this.tileFurnace.getEnergyStored(ForgeDirection.UNKNOWN)) iCraft.sendProgressBarUpdate(this, 3, this.tileFurnace.getEnergyStored(ForgeDirection.UNKNOWN));
|
if(this.lastEnergy != this.tileFurnace.storage.getEnergyStored()) iCraft.sendProgressBarUpdate(this, 3, this.tileFurnace.storage.getEnergyStored());
|
||||||
}
|
}
|
||||||
|
|
||||||
this.lastFirstCrushTime = this.tileFurnace.firstSmeltTime;
|
this.lastFirstCrushTime = this.tileFurnace.firstSmeltTime;
|
||||||
this.lastSecondCrushTime = this.tileFurnace.secondSmeltTime;
|
this.lastSecondCrushTime = this.tileFurnace.secondSmeltTime;
|
||||||
this.lastBurnTime = this.tileFurnace.maxBurnTime;
|
this.lastBurnTime = this.tileFurnace.maxBurnTime;
|
||||||
this.lastEnergy = this.tileFurnace.getEnergyStored(ForgeDirection.UNKNOWN);
|
this.lastEnergy = this.tileFurnace.storage.getEnergyStored();
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
|
|
@ -10,7 +10,6 @@ import net.minecraft.client.gui.inventory.GuiContainer;
|
||||||
import net.minecraft.entity.player.InventoryPlayer;
|
import net.minecraft.entity.player.InventoryPlayer;
|
||||||
import net.minecraft.util.ResourceLocation;
|
import net.minecraft.util.ResourceLocation;
|
||||||
import net.minecraft.util.StatCollector;
|
import net.minecraft.util.StatCollector;
|
||||||
import net.minecraftforge.common.util.ForgeDirection;
|
|
||||||
import org.lwjgl.opengl.GL11;
|
import org.lwjgl.opengl.GL11;
|
||||||
|
|
||||||
import java.util.Collections;
|
import java.util.Collections;
|
||||||
|
@ -44,7 +43,7 @@ public class GuiCanolaPress extends GuiContainer{
|
||||||
this.mc.getTextureManager().bindTexture(resLoc);
|
this.mc.getTextureManager().bindTexture(resLoc);
|
||||||
this.drawTexturedModalRect(this.guiLeft, this.guiTop, 0, 0, 176, 93);
|
this.drawTexturedModalRect(this.guiLeft, this.guiTop, 0, 0, 176, 93);
|
||||||
|
|
||||||
if(this.press.getEnergyStored(ForgeDirection.UNKNOWN) > 0){
|
if(this.press.storage.getEnergyStored() > 0){
|
||||||
int i = this.press.getEnergyScaled(83);
|
int i = this.press.getEnergyScaled(83);
|
||||||
drawTexturedModalRect(this.guiLeft + 43, this.guiTop+89-i, 176, 29, 16, i);
|
drawTexturedModalRect(this.guiLeft + 43, this.guiTop+89-i, 176, 29, 16, i);
|
||||||
}
|
}
|
||||||
|
@ -63,7 +62,7 @@ public class GuiCanolaPress extends GuiContainer{
|
||||||
@Override
|
@Override
|
||||||
public void drawScreen(int x, int y, float f){
|
public void drawScreen(int x, int y, float f){
|
||||||
super.drawScreen(x, y, f);
|
super.drawScreen(x, y, f);
|
||||||
String text1 = this.press.storage.getEnergyStored() + "/" + this.press.storage.getEnergyStored() + " RF";
|
String text1 = this.press.storage.getEnergyStored() + "/" + this.press.storage.getMaxEnergyStored() + " RF";
|
||||||
if(x >= guiLeft+43 && y >= guiTop+6 && x <= guiLeft+58 && y <= guiTop+88){
|
if(x >= guiLeft+43 && y >= guiTop+6 && x <= guiLeft+58 && y <= guiTop+88){
|
||||||
this.func_146283_a(Collections.singletonList(text1), x, y);
|
this.func_146283_a(Collections.singletonList(text1), x, y);
|
||||||
}
|
}
|
||||||
|
|
|
@ -9,7 +9,6 @@ import ellpeck.actuallyadditions.util.AssetUtil;
|
||||||
import net.minecraft.client.gui.inventory.GuiContainer;
|
import net.minecraft.client.gui.inventory.GuiContainer;
|
||||||
import net.minecraft.entity.player.InventoryPlayer;
|
import net.minecraft.entity.player.InventoryPlayer;
|
||||||
import net.minecraft.util.ResourceLocation;
|
import net.minecraft.util.ResourceLocation;
|
||||||
import net.minecraftforge.common.util.ForgeDirection;
|
|
||||||
import org.lwjgl.opengl.GL11;
|
import org.lwjgl.opengl.GL11;
|
||||||
|
|
||||||
import java.util.Collections;
|
import java.util.Collections;
|
||||||
|
@ -43,7 +42,7 @@ public class GuiCoalGenerator extends GuiContainer{
|
||||||
this.mc.getTextureManager().bindTexture(resLoc);
|
this.mc.getTextureManager().bindTexture(resLoc);
|
||||||
this.drawTexturedModalRect(this.guiLeft, this.guiTop, 0, 0, 176, 93);
|
this.drawTexturedModalRect(this.guiLeft, this.guiTop, 0, 0, 176, 93);
|
||||||
|
|
||||||
if(this.generator.getEnergyStored(ForgeDirection.UNKNOWN) > 0){
|
if(this.generator.storage.getEnergyStored() > 0){
|
||||||
int i = this.generator.getEnergyScaled(83);
|
int i = this.generator.getEnergyScaled(83);
|
||||||
drawTexturedModalRect(this.guiLeft+43, this.guiTop+89-i, 176, 0, 16, i);
|
drawTexturedModalRect(this.guiLeft+43, this.guiTop+89-i, 176, 0, 16, i);
|
||||||
}
|
}
|
||||||
|
|
|
@ -16,7 +16,6 @@ import net.minecraft.entity.player.InventoryPlayer;
|
||||||
import net.minecraft.util.ResourceLocation;
|
import net.minecraft.util.ResourceLocation;
|
||||||
import net.minecraft.util.StatCollector;
|
import net.minecraft.util.StatCollector;
|
||||||
import net.minecraft.world.World;
|
import net.minecraft.world.World;
|
||||||
import net.minecraftforge.common.util.ForgeDirection;
|
|
||||||
import net.minecraftforge.fluids.FluidRegistry;
|
import net.minecraftforge.fluids.FluidRegistry;
|
||||||
import org.lwjgl.opengl.GL11;
|
import org.lwjgl.opengl.GL11;
|
||||||
|
|
||||||
|
@ -74,7 +73,7 @@ public class GuiCoffeeMachine extends GuiContainer{
|
||||||
this.mc.getTextureManager().bindTexture(resLoc);
|
this.mc.getTextureManager().bindTexture(resLoc);
|
||||||
this.drawTexturedModalRect(this.guiLeft, this.guiTop, 0, 0, 176, 93);
|
this.drawTexturedModalRect(this.guiLeft, this.guiTop, 0, 0, 176, 93);
|
||||||
|
|
||||||
if(this.machine.getEnergyStored(ForgeDirection.UNKNOWN) > 0){
|
if(this.machine.storage.getEnergyStored() > 0){
|
||||||
int i = this.machine.getEnergyScaled(83);
|
int i = this.machine.getEnergyScaled(83);
|
||||||
drawTexturedModalRect(this.guiLeft+17, this.guiTop+89-i, 176, 0, 6, i);
|
drawTexturedModalRect(this.guiLeft+17, this.guiTop+89-i, 176, 0, 6, i);
|
||||||
}
|
}
|
||||||
|
@ -101,7 +100,7 @@ public class GuiCoffeeMachine extends GuiContainer{
|
||||||
public void drawScreen(int x, int y, float f){
|
public void drawScreen(int x, int y, float f){
|
||||||
super.drawScreen(x, y, f);
|
super.drawScreen(x, y, f);
|
||||||
|
|
||||||
String text1 = this.machine.storage.getEnergyStored() + "/" + this.machine.storage.getEnergyStored() + " RF";
|
String text1 = this.machine.storage.getEnergyStored() + "/" + this.machine.storage.getMaxEnergyStored() + " RF";
|
||||||
if(x >= guiLeft+16 && y >= guiTop+5 && x <= guiLeft+23 && y <= guiTop+89){
|
if(x >= guiLeft+16 && y >= guiTop+5 && x <= guiLeft+23 && y <= guiTop+89){
|
||||||
this.func_146283_a(Collections.singletonList(text1), x, y);
|
this.func_146283_a(Collections.singletonList(text1), x, y);
|
||||||
}
|
}
|
||||||
|
|
|
@ -9,7 +9,6 @@ import ellpeck.actuallyadditions.util.AssetUtil;
|
||||||
import net.minecraft.client.gui.inventory.GuiContainer;
|
import net.minecraft.client.gui.inventory.GuiContainer;
|
||||||
import net.minecraft.entity.player.InventoryPlayer;
|
import net.minecraft.entity.player.InventoryPlayer;
|
||||||
import net.minecraft.util.ResourceLocation;
|
import net.minecraft.util.ResourceLocation;
|
||||||
import net.minecraftforge.common.util.ForgeDirection;
|
|
||||||
import org.lwjgl.opengl.GL11;
|
import org.lwjgl.opengl.GL11;
|
||||||
|
|
||||||
import java.util.Collections;
|
import java.util.Collections;
|
||||||
|
@ -43,7 +42,7 @@ public class GuiEnergizer extends GuiContainer{
|
||||||
this.mc.getTextureManager().bindTexture(resLoc);
|
this.mc.getTextureManager().bindTexture(resLoc);
|
||||||
this.drawTexturedModalRect(this.guiLeft, this.guiTop, 0, 0, 176, 93);
|
this.drawTexturedModalRect(this.guiLeft, this.guiTop, 0, 0, 176, 93);
|
||||||
|
|
||||||
if(this.energizer.getEnergyStored(ForgeDirection.UNKNOWN) > 0){
|
if(this.energizer.storage.getEnergyStored() > 0){
|
||||||
int i = this.energizer.getEnergyScaled(83);
|
int i = this.energizer.getEnergyScaled(83);
|
||||||
drawTexturedModalRect(this.guiLeft+57, this.guiTop+89-i, 176, 0, 16, i);
|
drawTexturedModalRect(this.guiLeft+57, this.guiTop+89-i, 176, 0, 16, i);
|
||||||
}
|
}
|
||||||
|
@ -52,7 +51,7 @@ public class GuiEnergizer extends GuiContainer{
|
||||||
@Override
|
@Override
|
||||||
public void drawScreen(int x, int y, float f){
|
public void drawScreen(int x, int y, float f){
|
||||||
super.drawScreen(x, y, f);
|
super.drawScreen(x, y, f);
|
||||||
String text1 = this.energizer.storage.getEnergyStored() + "/" + this.energizer.storage.getEnergyStored() + " RF";
|
String text1 = this.energizer.storage.getEnergyStored() + "/" + this.energizer.storage.getMaxEnergyStored() + " RF";
|
||||||
if(x >= guiLeft+57 && y >= guiTop+6 && x <= guiLeft+72 && y <= guiTop+88){
|
if(x >= guiLeft+57 && y >= guiTop+6 && x <= guiLeft+72 && y <= guiTop+88){
|
||||||
this.func_146283_a(Collections.singletonList(text1), x, y);
|
this.func_146283_a(Collections.singletonList(text1), x, y);
|
||||||
}
|
}
|
||||||
|
|
|
@ -9,7 +9,6 @@ import ellpeck.actuallyadditions.util.AssetUtil;
|
||||||
import net.minecraft.client.gui.inventory.GuiContainer;
|
import net.minecraft.client.gui.inventory.GuiContainer;
|
||||||
import net.minecraft.entity.player.InventoryPlayer;
|
import net.minecraft.entity.player.InventoryPlayer;
|
||||||
import net.minecraft.util.ResourceLocation;
|
import net.minecraft.util.ResourceLocation;
|
||||||
import net.minecraftforge.common.util.ForgeDirection;
|
|
||||||
import org.lwjgl.opengl.GL11;
|
import org.lwjgl.opengl.GL11;
|
||||||
|
|
||||||
import java.util.Collections;
|
import java.util.Collections;
|
||||||
|
@ -43,7 +42,7 @@ public class GuiEnervator extends GuiContainer{
|
||||||
this.mc.getTextureManager().bindTexture(resLoc);
|
this.mc.getTextureManager().bindTexture(resLoc);
|
||||||
this.drawTexturedModalRect(this.guiLeft, this.guiTop, 0, 0, 176, 93);
|
this.drawTexturedModalRect(this.guiLeft, this.guiTop, 0, 0, 176, 93);
|
||||||
|
|
||||||
if(this.enervator.getEnergyStored(ForgeDirection.UNKNOWN) > 0){
|
if(this.enervator.storage.getEnergyStored() > 0){
|
||||||
int i = this.enervator.getEnergyScaled(83);
|
int i = this.enervator.getEnergyScaled(83);
|
||||||
drawTexturedModalRect(this.guiLeft+57, this.guiTop+89-i, 176, 0, 16, i);
|
drawTexturedModalRect(this.guiLeft+57, this.guiTop+89-i, 176, 0, 16, i);
|
||||||
}
|
}
|
||||||
|
|
|
@ -9,7 +9,6 @@ import ellpeck.actuallyadditions.util.AssetUtil;
|
||||||
import net.minecraft.client.gui.inventory.GuiContainer;
|
import net.minecraft.client.gui.inventory.GuiContainer;
|
||||||
import net.minecraft.entity.player.InventoryPlayer;
|
import net.minecraft.entity.player.InventoryPlayer;
|
||||||
import net.minecraft.util.ResourceLocation;
|
import net.minecraft.util.ResourceLocation;
|
||||||
import net.minecraftforge.common.util.ForgeDirection;
|
|
||||||
import org.lwjgl.opengl.GL11;
|
import org.lwjgl.opengl.GL11;
|
||||||
|
|
||||||
import java.util.Collections;
|
import java.util.Collections;
|
||||||
|
@ -42,7 +41,7 @@ public class GuiFurnaceDouble extends GuiContainer{
|
||||||
this.mc.getTextureManager().bindTexture(resLoc);
|
this.mc.getTextureManager().bindTexture(resLoc);
|
||||||
this.drawTexturedModalRect(this.guiLeft, this.guiTop, 0, 0, 176, 93);
|
this.drawTexturedModalRect(this.guiLeft, this.guiTop, 0, 0, 176, 93);
|
||||||
|
|
||||||
if(this.tileFurnace.getEnergyStored(ForgeDirection.UNKNOWN) > 0){
|
if(this.tileFurnace.storage.getEnergyStored() > 0){
|
||||||
int i = this.tileFurnace.getEnergyScaled(83);
|
int i = this.tileFurnace.getEnergyScaled(83);
|
||||||
drawTexturedModalRect(this.guiLeft+28, this.guiTop+89-i, 176, 44, 16, i);
|
drawTexturedModalRect(this.guiLeft+28, this.guiTop+89-i, 176, 44, 16, i);
|
||||||
}
|
}
|
||||||
|
@ -59,7 +58,7 @@ public class GuiFurnaceDouble extends GuiContainer{
|
||||||
@Override
|
@Override
|
||||||
public void drawScreen(int x, int y, float f){
|
public void drawScreen(int x, int y, float f){
|
||||||
super.drawScreen(x, y, f);
|
super.drawScreen(x, y, f);
|
||||||
String text = this.tileFurnace.storage.getEnergyStored() + "/" + this.tileFurnace.storage.getEnergyStored() + " RF";
|
String text = this.tileFurnace.storage.getEnergyStored() + "/" + this.tileFurnace.storage.getMaxEnergyStored() + " RF";
|
||||||
if(x >= guiLeft+28 && y >= guiTop+6 && x <= guiLeft+43 && y <= guiTop+88){
|
if(x >= guiLeft+28 && y >= guiTop+6 && x <= guiLeft+43 && y <= guiTop+88){
|
||||||
this.func_146283_a(Collections.singletonList(text), x, y);
|
this.func_146283_a(Collections.singletonList(text), x, y);
|
||||||
}
|
}
|
||||||
|
|
|
@ -9,7 +9,6 @@ import ellpeck.actuallyadditions.util.AssetUtil;
|
||||||
import net.minecraft.client.gui.inventory.GuiContainer;
|
import net.minecraft.client.gui.inventory.GuiContainer;
|
||||||
import net.minecraft.entity.player.InventoryPlayer;
|
import net.minecraft.entity.player.InventoryPlayer;
|
||||||
import net.minecraft.util.ResourceLocation;
|
import net.minecraft.util.ResourceLocation;
|
||||||
import net.minecraftforge.common.util.ForgeDirection;
|
|
||||||
import org.lwjgl.opengl.GL11;
|
import org.lwjgl.opengl.GL11;
|
||||||
|
|
||||||
import java.util.Collections;
|
import java.util.Collections;
|
||||||
|
@ -45,7 +44,7 @@ public class GuiGrinder extends GuiContainer{
|
||||||
this.mc.getTextureManager().bindTexture(this.isDouble ? resLocDouble : resLoc);
|
this.mc.getTextureManager().bindTexture(this.isDouble ? resLocDouble : resLoc);
|
||||||
this.drawTexturedModalRect(this.guiLeft, this.guiTop, 0, 0, 176, 93);
|
this.drawTexturedModalRect(this.guiLeft, this.guiTop, 0, 0, 176, 93);
|
||||||
|
|
||||||
if(this.tileGrinder.getEnergyStored(ForgeDirection.UNKNOWN) > 0){
|
if(this.tileGrinder.storage.getEnergyStored() > 0){
|
||||||
int i = this.tileGrinder.getEnergyScaled(83);
|
int i = this.tileGrinder.getEnergyScaled(83);
|
||||||
drawTexturedModalRect(this.guiLeft + (isDouble ? 14 : 43), this.guiTop+89-i, 176, (isDouble ? 44 : 23), 16, i);
|
drawTexturedModalRect(this.guiLeft + (isDouble ? 14 : 43), this.guiTop+89-i, 176, (isDouble ? 44 : 23), 16, i);
|
||||||
}
|
}
|
||||||
|
@ -64,7 +63,7 @@ public class GuiGrinder extends GuiContainer{
|
||||||
@Override
|
@Override
|
||||||
public void drawScreen(int x, int y, float f){
|
public void drawScreen(int x, int y, float f){
|
||||||
super.drawScreen(x, y, f);
|
super.drawScreen(x, y, f);
|
||||||
String text = this.tileGrinder.storage.getEnergyStored() + "/" + this.tileGrinder.storage.getEnergyStored() + " RF";
|
String text = this.tileGrinder.storage.getEnergyStored() + "/" + this.tileGrinder.storage.getMaxEnergyStored() + " RF";
|
||||||
if((this.isDouble && x >= guiLeft+14 && y >= guiTop+6 && x <= guiLeft+29 && y <= guiTop+88) || (!this.isDouble && x >= guiLeft+43 && y >= guiTop+6 && x <= guiLeft+58 && y <= guiTop+88)){
|
if((this.isDouble && x >= guiLeft+14 && y >= guiTop+6 && x <= guiLeft+29 && y <= guiTop+88) || (!this.isDouble && x >= guiLeft+43 && y >= guiTop+6 && x <= guiLeft+58 && y <= guiTop+88)){
|
||||||
this.func_146283_a(Collections.singletonList(text), x, y);
|
this.func_146283_a(Collections.singletonList(text), x, y);
|
||||||
}
|
}
|
||||||
|
|
|
@ -10,7 +10,6 @@ import net.minecraft.client.gui.inventory.GuiContainer;
|
||||||
import net.minecraft.entity.player.InventoryPlayer;
|
import net.minecraft.entity.player.InventoryPlayer;
|
||||||
import net.minecraft.util.ResourceLocation;
|
import net.minecraft.util.ResourceLocation;
|
||||||
import net.minecraft.util.StatCollector;
|
import net.minecraft.util.StatCollector;
|
||||||
import net.minecraftforge.common.util.ForgeDirection;
|
|
||||||
import org.lwjgl.opengl.GL11;
|
import org.lwjgl.opengl.GL11;
|
||||||
|
|
||||||
import java.util.Collections;
|
import java.util.Collections;
|
||||||
|
@ -44,7 +43,7 @@ public class GuiOilGenerator extends GuiContainer{
|
||||||
this.mc.getTextureManager().bindTexture(resLoc);
|
this.mc.getTextureManager().bindTexture(resLoc);
|
||||||
this.drawTexturedModalRect(this.guiLeft, this.guiTop, 0, 0, 176, 93);
|
this.drawTexturedModalRect(this.guiLeft, this.guiTop, 0, 0, 176, 93);
|
||||||
|
|
||||||
if(this.generator.getEnergyStored(ForgeDirection.UNKNOWN) > 0){
|
if(this.generator.storage.getEnergyStored() > 0){
|
||||||
int i = this.generator.getEnergyScaled(83);
|
int i = this.generator.getEnergyScaled(83);
|
||||||
drawTexturedModalRect(this.guiLeft+43, this.guiTop+89-i, 176, 0, 16, i);
|
drawTexturedModalRect(this.guiLeft+43, this.guiTop+89-i, 176, 0, 16, i);
|
||||||
}
|
}
|
||||||
|
|
|
@ -9,7 +9,6 @@ import ellpeck.actuallyadditions.util.AssetUtil;
|
||||||
import net.minecraft.client.gui.inventory.GuiContainer;
|
import net.minecraft.client.gui.inventory.GuiContainer;
|
||||||
import net.minecraft.entity.player.InventoryPlayer;
|
import net.minecraft.entity.player.InventoryPlayer;
|
||||||
import net.minecraft.util.ResourceLocation;
|
import net.minecraft.util.ResourceLocation;
|
||||||
import net.minecraftforge.common.util.ForgeDirection;
|
|
||||||
import org.lwjgl.opengl.GL11;
|
import org.lwjgl.opengl.GL11;
|
||||||
|
|
||||||
import java.util.Collections;
|
import java.util.Collections;
|
||||||
|
@ -42,7 +41,7 @@ public class GuiRepairer extends GuiContainer{
|
||||||
this.mc.getTextureManager().bindTexture(resLoc);
|
this.mc.getTextureManager().bindTexture(resLoc);
|
||||||
this.drawTexturedModalRect(this.guiLeft, this.guiTop, 0, 0, 176, 93);
|
this.drawTexturedModalRect(this.guiLeft, this.guiTop, 0, 0, 176, 93);
|
||||||
|
|
||||||
if(this.tileRepairer.getEnergyStored(ForgeDirection.UNKNOWN) > 0){
|
if(this.tileRepairer.storage.getEnergyStored() > 0){
|
||||||
int i = this.tileRepairer.getEnergyScaled(83);
|
int i = this.tileRepairer.getEnergyScaled(83);
|
||||||
drawTexturedModalRect(this.guiLeft+28, this.guiTop+89-i, 176, 44, 16, i);
|
drawTexturedModalRect(this.guiLeft+28, this.guiTop+89-i, 176, 44, 16, i);
|
||||||
}
|
}
|
||||||
|
@ -55,7 +54,7 @@ public class GuiRepairer extends GuiContainer{
|
||||||
@Override
|
@Override
|
||||||
public void drawScreen(int x, int y, float f){
|
public void drawScreen(int x, int y, float f){
|
||||||
super.drawScreen(x, y, f);
|
super.drawScreen(x, y, f);
|
||||||
String text = this.tileRepairer.storage.getEnergyStored() + "/" + this.tileRepairer.storage.getEnergyStored() + " RF";
|
String text = this.tileRepairer.storage.getEnergyStored() + "/" + this.tileRepairer.storage.getMaxEnergyStored() + " RF";
|
||||||
if(x >= guiLeft+28 && y >= guiTop+6 && x <= guiLeft+43 && y <= guiTop+88){
|
if(x >= guiLeft+28 && y >= guiTop+6 && x <= guiLeft+43 && y <= guiTop+88){
|
||||||
this.func_146283_a(Collections.singletonList(text), x, y);
|
this.func_146283_a(Collections.singletonList(text), x, y);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue