Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update to 7.2pr2 #2

Merged
merged 2 commits into from
Jul 14, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions gradle.properties
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
org.gradle.jvmargs=-Xmx4G

# BTA
bta_version=7.1
bta_version=7.2-pre2

# Loader & Mod Menu
loader_version=0.15.6-babric.4-bta
loader_version=0.15.6-babric.6-bta
mod_menu_version=2.0.5

# HalpLibe
halplibe_version=3.5.2
halplibe_version=4.1.3

# Mod
mod_version=1.2.1
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,16 +2,17 @@

import net.minecraft.client.option.GameSettings;
import net.minecraft.client.option.KeyBinding;
import net.minecraft.client.input.InputDevice;
import org.spongepowered.asm.mixin.Mixin;
import rootenginear.sortchest.interfaces.ISortChestSettings;

@Mixin(value = GameSettings.class, remap = false)
public class GameSettingsMixin implements ISortChestSettings {

public KeyBinding keyRefill = new KeyBinding("sortchest.refill").bindKeyboard(0x13); //R
public KeyBinding keyFill = new KeyBinding("sortchest.fill").bindKeyboard(0x21); //F
public KeyBinding keyDump = new KeyBinding("sortchest.dump").bindKeyboard(0x20); //D
public KeyBinding keySort = new KeyBinding("sortchest.sort").bindKeyboard(0x1F); //S
public KeyBinding keyRefill = new KeyBinding("sortchest.refill").setDefault(InputDevice.keyboard, 0x13); //R
public KeyBinding keyFill = new KeyBinding("sortchest.fill").setDefault(InputDevice.keyboard, 0x21); //F
public KeyBinding keyDump = new KeyBinding("sortchest.dump").setDefault(InputDevice.keyboard, 0x20); //D
public KeyBinding keySort = new KeyBinding("sortchest.sort").setDefault(InputDevice.keyboard, 0x1F); //S

@Override
public KeyBinding bta_rootenginear_mods$getKeySort() {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@
import org.spongepowered.asm.mixin.injection.callback.CallbackInfo;
import rootenginear.sortchest.gui.GuiSortChestButton;
import rootenginear.sortchest.interfaces.ISortChestSettings;
import rootenginear.sortchest.mixin.accessor.GuiChestAccessor;
import rootenginear.sortchest.utils.Utils;

import java.util.ArrayList;
Expand Down Expand Up @@ -66,7 +65,7 @@ private void doSort(char c, int _i, int mouseX, int mouseY, CallbackInfo ci) {
return;
}

int countInvSlots = ((GuiChestAccessor) this).getInventoryRows() * 9;
int countInvSlots = this.inventorySlots.inventorySlots.size() - 36;

if (key == keyFill) {
dumpItemToChest(playerController, entityPlayer, windowId, countInvSlots);
Expand Down

This file was deleted.

3 changes: 2 additions & 1 deletion src/main/java/rootenginear/sortchest/utils/Utils.java
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@

public class Utils {
public static boolean isNotChest(Object object) {
return !(object instanceof GuiChest);
String name = object.getClass().getSimpleName();
return !(object instanceof GuiChest) && !name.equals("ContainerWideChest") && !name.equals("GuiDiamondChest") && !name.equals("GuiIronChest");
}
}
2 changes: 1 addition & 1 deletion src/main/resources/fabric.mod.json
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@
"sortchest.mixins.json"
],
"depends": {
"minecraft": "7.1",
"minecraft": "~7.2-beta.2",
"fabricloader": ">=0.15.5",
"halplibe": ">=3.5.2"
},
Expand Down
1 change: 0 additions & 1 deletion src/main/resources/sortchest.mixins.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@
"GameSettingsMixin",
"GuiContainerMixin",
"GuiScreenMixin",
"accessor.GuiChestAccessor"
],
"injectors": {
"defaultRequire": 1
Expand Down
Loading