From e2a0d7dd9e175b1b65a67baa55ff8df3f63cc32c Mon Sep 17 00:00:00 2001 From: IMS212 Date: Thu, 16 Nov 2023 08:54:25 -0800 Subject: [PATCH] here's source --- buildscript/src/main/java/Buildscript.java | 4 ++-- .../element/IrisContainerObjectSelectionList.java | 5 +---- .../iris/gui/element/IrisObjectSelectionList.java | 7 ++----- .../iris/gui/element/ShaderPackOptionList.java | 9 +++++---- .../iris/gui/element/ShaderPackSelectionList.java | 13 +++++++------ 5 files changed, 17 insertions(+), 21 deletions(-) diff --git a/buildscript/src/main/java/Buildscript.java b/buildscript/src/main/java/Buildscript.java index 36806cd8da..8a4345ce84 100644 --- a/buildscript/src/main/java/Buildscript.java +++ b/buildscript/src/main/java/Buildscript.java @@ -45,8 +45,8 @@ public class Buildscript extends SimpleFabricProject { static final boolean SODIUM = true; static final boolean CUSTOM_SODIUM = true; - static final String MC_VERSION = "23w45a"; - static final String customSodiumName = "sodium-fabric-mc23w42a-0.5.3git.b1ba94f.jar"; + static final String MC_VERSION = "23w46a"; + static final String customSodiumName = "sodium-fabric-mc23w45a-0.5.3git.86b69d2-dirty.jar"; private static final String[] SOURCE_SETS = new String[] { "main", diff --git a/src/main/java/net/coderbot/iris/gui/element/IrisContainerObjectSelectionList.java b/src/main/java/net/coderbot/iris/gui/element/IrisContainerObjectSelectionList.java index ec1a70589d..c292005552 100644 --- a/src/main/java/net/coderbot/iris/gui/element/IrisContainerObjectSelectionList.java +++ b/src/main/java/net/coderbot/iris/gui/element/IrisContainerObjectSelectionList.java @@ -8,10 +8,7 @@ public class IrisContainerObjectSelectionList> extends ContainerObjectSelectionList { public IrisContainerObjectSelectionList(Minecraft client, int width, int height, int top, int bottom, int left, int right, int itemHeight) { - super(client, width, height, top, bottom, itemHeight); - - this.x0 = left; - this.x1 = right; + super(client, width, height, top, itemHeight); } @Override diff --git a/src/main/java/net/coderbot/iris/gui/element/IrisObjectSelectionList.java b/src/main/java/net/coderbot/iris/gui/element/IrisObjectSelectionList.java index 91f48c415d..618f2dcbb7 100644 --- a/src/main/java/net/coderbot/iris/gui/element/IrisObjectSelectionList.java +++ b/src/main/java/net/coderbot/iris/gui/element/IrisObjectSelectionList.java @@ -8,10 +8,7 @@ public class IrisObjectSelectionList> extends AbstractSelectionList { public IrisObjectSelectionList(Minecraft client, int width, int height, int top, int bottom, int left, int right, int itemHeight) { - super(client, width, height, top, bottom, itemHeight); - - this.x0 = left; - this.x1 = right; + super(client, width, height, top, itemHeight); } @Override @@ -26,7 +23,7 @@ public void select(int entry) { } @Override - public void updateNarration(NarrationElementOutput p0) { + public void updateWidgetNarration(NarrationElementOutput p0) { } } diff --git a/src/main/java/net/coderbot/iris/gui/element/ShaderPackOptionList.java b/src/main/java/net/coderbot/iris/gui/element/ShaderPackOptionList.java index 9df2e00650..8aad40fe20 100644 --- a/src/main/java/net/coderbot/iris/gui/element/ShaderPackOptionList.java +++ b/src/main/java/net/coderbot/iris/gui/element/ShaderPackOptionList.java @@ -50,6 +50,7 @@ public ShaderPackOptionList(ShaderPackScreen screen, NavigationController naviga super(client, width, height, top, bottom, left, right, 24); this.navigation = navigation; this.screen = screen; + this.setRenderBackground(false); applyShaderPack(pack); } @@ -59,12 +60,12 @@ protected void renderDecorations(GuiGraphics pAbstractSelectionList0, int pInt1, // Renders top/bottom dirt int lvInt9 = 32; pAbstractSelectionList0.setColor(0.25F, 0.25F, 0.25F, 1.0F); - pAbstractSelectionList0.blit(Screen.BACKGROUND_LOCATION, this.x0, 0, 0.0F, 0.0F, this.width, this.y0, 32, 32); - pAbstractSelectionList0.blit(Screen.BACKGROUND_LOCATION, this.x0, this.y1, 0.0F, (float)this.y1, this.width, this.height - this.y1, 32, 32); + pAbstractSelectionList0.blit(Screen.BACKGROUND_LOCATION, this.getX(), 0, 0.0F, 0.0F, this.width, this.getY(), 32, 32); + pAbstractSelectionList0.blit(Screen.BACKGROUND_LOCATION, this.getX(), this.getBottom(), 0.0F, (float)this.getBottom(), this.width, this.height - this.getBottom(), 32, 32); pAbstractSelectionList0.setColor(1.0F, 1.0F, 1.0F, 1.0F); int lvInt10 = 4; - pAbstractSelectionList0.fillGradient(RenderType.guiOverlay(), this.x0, this.y0, this.x1, this.y0 + 4, -16777216, 0, 0); - pAbstractSelectionList0.fillGradient(RenderType.guiOverlay(), this.x0, this.y1 - 4, this.x1, this.y1, 0, -16777216, 0); + pAbstractSelectionList0.fillGradient(RenderType.guiOverlay(), this.getX(), this.getY(), this.getRight(), this.getY() + 4, -16777216, 0, 0); + pAbstractSelectionList0.fillGradient(RenderType.guiOverlay(), this.getX(), this.getBottom() - 4, this.getRight(), this.getBottom(), 0, -16777216, 0); super.renderDecorations(pAbstractSelectionList0, pInt1, pInt2); } diff --git a/src/main/java/net/coderbot/iris/gui/element/ShaderPackSelectionList.java b/src/main/java/net/coderbot/iris/gui/element/ShaderPackSelectionList.java index e2cbdebbc4..d51d06199e 100644 --- a/src/main/java/net/coderbot/iris/gui/element/ShaderPackSelectionList.java +++ b/src/main/java/net/coderbot/iris/gui/element/ShaderPackSelectionList.java @@ -52,6 +52,7 @@ public ShaderPackSelectionList(ShaderPackScreen screen, Minecraft client, int wi super(client, width, height, top, bottom, left, right, 20); WatchKey key1; WatchService watcher1; + this.setRenderBackground(false); this.screen = screen; this.topButtonRow = new TopButtonRowEntry(this, Iris.getIrisConfig().areShadersEnabled()); @@ -84,7 +85,7 @@ public boolean keyPressed(int pContainerEventHandler0, int pInt1, int pInt2) { } @Override - public void render(GuiGraphics pAbstractSelectionList0, int pInt1, int pInt2, float pFloat3) { + public void renderWidget(GuiGraphics pAbstractSelectionList0, int pInt1, int pInt2, float pFloat3) { if (keyValid) { for (WatchEvent event : key.pollEvents()) { if (event.kind() == StandardWatchEventKinds.OVERFLOW) continue; @@ -96,7 +97,7 @@ public void render(GuiGraphics pAbstractSelectionList0, int pInt1, int pInt2, fl keyValid = key.reset(); } - super.render(pAbstractSelectionList0, pInt1, pInt2, pFloat3); + super.renderWidget(pAbstractSelectionList0, pInt1, pInt2, pFloat3); } public void close() throws IOException { @@ -183,12 +184,12 @@ protected void renderDecorations(GuiGraphics pAbstractSelectionList0, int pInt1, // Renders top/bottom dirt int lvInt9 = 32; pAbstractSelectionList0.setColor(0.25F, 0.25F, 0.25F, 1.0F); - pAbstractSelectionList0.blit(Screen.BACKGROUND_LOCATION, this.x0, 0, 0.0F, 0.0F, this.width, this.y0, 32, 32); - pAbstractSelectionList0.blit(Screen.BACKGROUND_LOCATION, this.x0, this.y1, 0.0F, (float)this.y1, this.width, this.height - this.y1, 32, 32); + pAbstractSelectionList0.blit(Screen.BACKGROUND_LOCATION, this.getX(), 0, 0.0F, 0.0F, this.width, this.getHeight(), 32, 32); + pAbstractSelectionList0.blit(Screen.BACKGROUND_LOCATION, this.getX(), this.getBottom(), 0.0F, (float)this.getBottom(), this.width, this.height - this.getBottom(), 32, 32); pAbstractSelectionList0.setColor(1.0F, 1.0F, 1.0F, 1.0F); int lvInt10 = 4; - pAbstractSelectionList0.fillGradient(RenderType.guiOverlay(), this.x0, this.y0, this.x1, this.y0 + 4, -16777216, 0, 0); - pAbstractSelectionList0.fillGradient(RenderType.guiOverlay(), this.x0, this.y1 - 4, this.x1, this.y1, 0, -16777216, 0); + pAbstractSelectionList0.fillGradient(RenderType.guiOverlay(), this.getX(), this.getHeight(), this.getRight(), this.getHeight() + 4, -16777216, 0, 0); + pAbstractSelectionList0.fillGradient(RenderType.guiOverlay(), this.getX(), this.getBottom() - 4, this.getRight(), this.getBottom(), 0, -16777216, 0); super.renderDecorations(pAbstractSelectionList0, pInt1, pInt2); }