diff --git a/gradle.properties b/gradle.properties index a773582..1ac5a24 100644 --- a/gradle.properties +++ b/gradle.properties @@ -11,7 +11,7 @@ loader_version=0.15.11 fabric_version=0.100.4+1.21 # Mod Properties -mod_version=3.0.1 +mod_version=3.0.2 maven_group=systems.brn archives_base_name=Server_storage diff --git a/src/main/java/systems/brn/server_storage/blocks/InventoryInterfaceBlock.java b/src/main/java/systems/brn/server_storage/blocks/InventoryInterfaceBlock.java index c58e395..2dd169b 100644 --- a/src/main/java/systems/brn/server_storage/blocks/InventoryInterfaceBlock.java +++ b/src/main/java/systems/brn/server_storage/blocks/InventoryInterfaceBlock.java @@ -133,9 +133,13 @@ public class InventoryInterfaceBlock extends ConnectedBlock implements PolymerTe .hideDefaultTooltip().noDefaults() .setSkullOwner(GUI_QUESTION_MARK) .setCallback((x, y, z) -> { - SearchScreen searchScreen = new SearchScreen(settingsScreen, ""); playClickSound(settingsScreen.getPlayer()); - searchScreen.open(); + if (y.isRight) { + blockEntity.doSearch(""); + } else if (y.isLeft) { + SearchScreen searchScreen = new SearchScreen(settingsScreen, ""); + searchScreen.open(); + } }) )); } diff --git a/src/main/java/systems/brn/server_storage/screens/StorageScreen.java b/src/main/java/systems/brn/server_storage/screens/StorageScreen.java index 35f7f31..a20634d 100644 --- a/src/main/java/systems/brn/server_storage/screens/StorageScreen.java +++ b/src/main/java/systems/brn/server_storage/screens/StorageScreen.java @@ -147,9 +147,13 @@ public class StorageScreen extends PagedGui { .hideDefaultTooltip().noDefaults() .setSkullOwner(GUI_QUESTION_MARK) .setCallback((x, y, z) -> { - SearchScreen searchScreen = new SearchScreen(this, ""); playClickSound(getPlayer()); - searchScreen.open(); + if (y.isRight) { + doSearch(""); + } else if (y.isLeft) { + SearchScreen searchScreen = new SearchScreen(this, ""); + searchScreen.open(); + } }) ); }