diff options
| author | Martin Robertz <dream-master@gmx.net> | 2022-10-09 12:12:31 +0200 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2022-10-09 12:12:31 +0200 |
| commit | f7ffab4b1f0ef45dd4852b26965367f2c559ca0a (patch) | |
| tree | 2e94fcd7517921328eebb51abe506f99b9a10dd5 /src/main/java/client/gui/GUIContainer_ModularNuclearReactor.java | |
| parent | 7f193e090a535bf026e92f17a676f78d7771277f (diff) | |
| parent | 145e13b90195d9d58f5629fb1c2d1c90b9a5b1b1 (diff) | |
| download | GT5-Unofficial-f7ffab4b1f0ef45dd4852b26965367f2c559ca0a.tar.gz GT5-Unofficial-f7ffab4b1f0ef45dd4852b26965367f2c559ca0a.tar.bz2 GT5-Unofficial-f7ffab4b1f0ef45dd4852b26965367f2c559ca0a.zip | |
Merge pull request #44 from GTNewHorizons/fix/lsc-division-zero
Fix division by zero error
Diffstat (limited to 'src/main/java/client/gui/GUIContainer_ModularNuclearReactor.java')
| -rw-r--r-- | src/main/java/client/gui/GUIContainer_ModularNuclearReactor.java | 86 |
1 files changed, 40 insertions, 46 deletions
diff --git a/src/main/java/client/gui/GUIContainer_ModularNuclearReactor.java b/src/main/java/client/gui/GUIContainer_ModularNuclearReactor.java index d6f2a61ce4..eabbb26ff1 100644 --- a/src/main/java/client/gui/GUIContainer_ModularNuclearReactor.java +++ b/src/main/java/client/gui/GUIContainer_ModularNuclearReactor.java @@ -1,46 +1,40 @@ -package client.gui;
-
-import org.lwjgl.opengl.GL11;
-
-import common.container.Container_ModularNuclearReactor;
-import gregtech.api.interfaces.tileentity.IGregTechTileEntity;
-import kekztech.KekzCore;
-import net.minecraft.client.Minecraft;
-import net.minecraft.client.gui.inventory.GuiContainer;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.entity.player.InventoryPlayer;
-import net.minecraft.util.ResourceLocation;
-
-public class GUIContainer_ModularNuclearReactor extends GuiContainer {
-
- private ResourceLocation texture = new ResourceLocation(KekzCore.MODID, "textures/gui/MultiblockDisplay_REACTOR.png");
-
- private InventoryPlayer inventory;
- private IGregTechTileEntity te;
-
- public GUIContainer_ModularNuclearReactor(IGregTechTileEntity te, EntityPlayer player)
- {
- super(new Container_ModularNuclearReactor(te, player));
- inventory = player.inventory;
- this.te = te;
- }
-
- @Override
- protected void drawGuiContainerBackgroundLayer(float par1, int par2, int par3)
- {
- Minecraft.getMinecraft().renderEngine.bindTexture(texture);
-
- GL11.glColor4f(1.0F, 1.0F, 1.0F, 1.0F);
-
- final int x = (super.width - super.xSize) / 2;
- final int y = (super.height - super.ySize) / 2;
- super.drawTexturedModalRect(x, y, 0, 0, super.xSize, super.ySize);
- }
-
- @Override
- protected void drawGuiContainerForegroundLayer(int par1, int par2)
- {
-
- }
-
-}
+package client.gui; + +import common.container.Container_ModularNuclearReactor; +import gregtech.api.interfaces.tileentity.IGregTechTileEntity; +import kekztech.KekzCore; +import net.minecraft.client.Minecraft; +import net.minecraft.client.gui.inventory.GuiContainer; +import net.minecraft.entity.player.EntityPlayer; +import net.minecraft.entity.player.InventoryPlayer; +import net.minecraft.util.ResourceLocation; +import org.lwjgl.opengl.GL11; + +public class GUIContainer_ModularNuclearReactor extends GuiContainer { + + private ResourceLocation texture = + new ResourceLocation(KekzCore.MODID, "textures/gui/MultiblockDisplay_REACTOR.png"); + + private InventoryPlayer inventory; + private IGregTechTileEntity te; + + public GUIContainer_ModularNuclearReactor(IGregTechTileEntity te, EntityPlayer player) { + super(new Container_ModularNuclearReactor(te, player)); + inventory = player.inventory; + this.te = te; + } + + @Override + protected void drawGuiContainerBackgroundLayer(float par1, int par2, int par3) { + Minecraft.getMinecraft().renderEngine.bindTexture(texture); + + GL11.glColor4f(1.0F, 1.0F, 1.0F, 1.0F); + + final int x = (super.width - super.xSize) / 2; + final int y = (super.height - super.ySize) / 2; + super.drawTexturedModalRect(x, y, 0, 0, super.xSize, super.ySize); + } + + @Override + protected void drawGuiContainerForegroundLayer(int par1, int par2) {} +} |
