From 9d592189095b968c0c9c49dc5b2fbf2fcde47612 Mon Sep 17 00:00:00 2001 From: BallOfEnergy <66693744+BallOfEnergy1@users.noreply.github.com> Date: Sat, 17 Aug 2024 12:26:08 -0500 Subject: [PATCH] aaaaaaaaaaaaa --- .../hbm/inventory/gui/GUIMachineRefinery.java | 58 +++++++++++-------- 1 file changed, 33 insertions(+), 25 deletions(-) diff --git a/src/main/java/com/hbm/inventory/gui/GUIMachineRefinery.java b/src/main/java/com/hbm/inventory/gui/GUIMachineRefinery.java index 0db5f2f29..95aed769b 100644 --- a/src/main/java/com/hbm/inventory/gui/GUIMachineRefinery.java +++ b/src/main/java/com/hbm/inventory/gui/GUIMachineRefinery.java @@ -85,38 +85,46 @@ public class GUIMachineRefinery extends GuiInfoContainer { Tuple.Quintet recipe = RefineryRecipes.getRefinery(inputOil.getTankType()); - // Heavy Oil Products - Color color = new Color(recipe.getV().type.getColor()); + if(recipe == null) { + func_146110_a(guiLeft + 52, guiTop + 63, 247, 1, 33, 48, 350, 256); + func_146110_a(guiLeft + 52, guiTop + 32, 247, 50, 66, 52, 350, 256); + func_146110_a(guiLeft + 52, guiTop + 24, 247, 145, 86, 35, 350, 256); + func_146110_a(guiLeft + 36, guiTop + 16, 211, 119, 122, 25, 350, 256); + } else { - GL11.glEnable(GL11.GL_BLEND); - GL11.glColor4f(color.getRed() / 255F, color.getGreen() / 255F, color.getBlue() / 255F, 1F); - func_146110_a(guiLeft + 52, guiTop + 63, 247, 1, 33, 48, 350, 256); - GL11.glDisable(GL11.GL_BLEND); + // Heavy Oil Products + Color color = new Color(recipe.getV().type.getColor()); - // Naphtha Oil Products - color = new Color(recipe.getW().type.getColor()); + GL11.glEnable(GL11.GL_BLEND); + GL11.glColor4f(color.getRed() / 255F, color.getGreen() / 255F, color.getBlue() / 255F, 1F); + func_146110_a(guiLeft + 52, guiTop + 63, 247, 1, 33, 48, 350, 256); + GL11.glDisable(GL11.GL_BLEND); - GL11.glEnable(GL11.GL_BLEND); - GL11.glColor4f(color.getRed() / 255F, color.getGreen() / 255F, color.getBlue() / 255F, 1F); - func_146110_a(guiLeft + 52, guiTop + 32, 247, 50, 66, 52, 350, 256); - GL11.glDisable(GL11.GL_BLEND); + // Naphtha Oil Products + color = new Color(recipe.getW().type.getColor()); - // Light Oil Products - color = new Color(recipe.getX().type.getColor()); + GL11.glEnable(GL11.GL_BLEND); + GL11.glColor4f(color.getRed() / 255F, color.getGreen() / 255F, color.getBlue() / 255F, 1F); + func_146110_a(guiLeft + 52, guiTop + 32, 247, 50, 66, 52, 350, 256); + GL11.glDisable(GL11.GL_BLEND); - GL11.glEnable(GL11.GL_BLEND); - GL11.glColor4f(color.getRed() / 255F, color.getGreen() / 255F, color.getBlue() / 255F, 1F); - func_146110_a(guiLeft + 52, guiTop + 24, 247, 145, 86, 35, 350, 256); - GL11.glDisable(GL11.GL_BLEND); + // Light Oil Products + color = new Color(recipe.getX().type.getColor()); - // Gaseous Products - color = new Color(recipe.getY().type.getColor()); + GL11.glEnable(GL11.GL_BLEND); + GL11.glColor4f(color.getRed() / 255F, color.getGreen() / 255F, color.getBlue() / 255F, 1F); + func_146110_a(guiLeft + 52, guiTop + 24, 247, 145, 86, 35, 350, 256); + GL11.glDisable(GL11.GL_BLEND); - GL11.glEnable(GL11.GL_BLEND); - GL11.glColor4f(color.getRed() / 255F, color.getGreen() / 255F, color.getBlue() / 255F, 1F); - func_146110_a(guiLeft + 36, guiTop + 16, 211, 119, 122, 25, 350, 256); - GL11.glDisable(GL11.GL_BLEND); - GL11.glColor4f(1F, 1F, 1F, 1F); + // Gaseous Products + color = new Color(recipe.getY().type.getColor()); + + GL11.glEnable(GL11.GL_BLEND); + GL11.glColor4f(color.getRed() / 255F, color.getGreen() / 255F, color.getBlue() / 255F, 1F); + func_146110_a(guiLeft + 36, guiTop + 16, 211, 119, 122, 25, 350, 256); + GL11.glDisable(GL11.GL_BLEND); + GL11.glColor4f(1F, 1F, 1F, 1F); + } // output tanks refinery.tanks[1].renderTank(guiLeft + 86, guiTop + 95, this.zLevel, 16, 52);