From c633a1f52e3137e406c7b467c62b4d250964f263 Mon Sep 17 00:00:00 2001 From: zontreck Date: Tue, 9 Jan 2024 14:44:44 -0700 Subject: [PATCH] Fixes a minor typo --- gradle.properties | 2 +- .../java/dev/zontreck/libzontreck/chestgui/ChestGUI.java | 6 +----- .../java/dev/zontreck/libzontreck/menus/ChestGUIMenu.java | 1 + 3 files changed, 3 insertions(+), 6 deletions(-) diff --git a/gradle.properties b/gradle.properties index 1e0798d..fb7ff35 100644 --- a/gradle.properties +++ b/gradle.properties @@ -53,7 +53,7 @@ mod_name=Zontreck Library Mod # The license of the mod. Review your options at https://choosealicense.com/. All Rights Reserved is the default. mod_license=GPLv3 # The mod version. See https://semver.org/ -mod_version=1.10.010924.1421 +mod_version=1.10.010924.1444 # The group ID for the mod. It is only important when publishing as an artifact to a Maven repository. # This should match the base package used for the mod sources. # See https://maven.apache.org/guides/mini/guide-naming-conventions.html diff --git a/src/main/java/dev/zontreck/libzontreck/chestgui/ChestGUI.java b/src/main/java/dev/zontreck/libzontreck/chestgui/ChestGUI.java index ca879f9..ef3d358 100644 --- a/src/main/java/dev/zontreck/libzontreck/chestgui/ChestGUI.java +++ b/src/main/java/dev/zontreck/libzontreck/chestgui/ChestGUI.java @@ -75,8 +75,6 @@ public class ChestGUI public void nextPage() { page++; - - checkPageButtons(); } /** @@ -85,8 +83,6 @@ public class ChestGUI public void prevPage() { page--; - - checkPageButtons(); } /* @@ -173,7 +169,7 @@ public class ChestGUI ItemStack forwardStack = new ItemStack(ModItems.CHESTGUI_FORWARD.get(), 1); ChestGUIButton nxt = new ChestGUIButton(forwardStack, ()->{ close(); - prevPage(); + nextPage(); open(); }, new Vector2i(3, 8)); diff --git a/src/main/java/dev/zontreck/libzontreck/menus/ChestGUIMenu.java b/src/main/java/dev/zontreck/libzontreck/menus/ChestGUIMenu.java index 65e40a0..83b0ac2 100644 --- a/src/main/java/dev/zontreck/libzontreck/menus/ChestGUIMenu.java +++ b/src/main/java/dev/zontreck/libzontreck/menus/ChestGUIMenu.java @@ -35,6 +35,7 @@ public class ChestGUIMenu extends AbstractContainerMenu super(ModMenuTypes.CHEST_GUI_MENU.get(), id); this.gui = gui; + gui.checkPageButtons(); this.player = player; slots = new ChestGUIReadOnlyStackHandler(gui, player);