Merge remote-tracking branch 'lordIcocain/magnet-and-restock' into dev

This commit is contained in:
Martin Robertz committed 2025-05-26 08:13:07 +02:00
commit b3ebd65461
3 files changed
+8 -7

No files matched your search

@@ -71,10 +71,10 @@ public class GuiFCImgButton extends GuiButton implements ITooltip {
this.registerApp(30, "MAGNET_CARD", "ME", "magnet_card.me");
this.registerApp(30, "MAGNET_CARD", "FILTER", "magnet_card.filter");
this.registerApp(31, "MAGNET_CARD", "OFF", "magnet_card.off");
this.registerApp(33, "ENABLE_12x", "ENABLE", "enable");
this.registerApp(34, "DISABLE_12x", "DISABLE", "disable");
this.registerApp(36, "RESTOCK", "ENABLE", "restock.on");
this.registerApp(37, "RESTOCK", "DISABLE", "restock.off");
this.registerApp(32, "ENABLE_12x", "ENABLE", "enable");
this.registerApp(33, "DISABLE_12x", "DISABLE", "disable");
this.registerApp(34, "RESTOCK", "ENABLE", "restock.on");
this.registerApp(35, "RESTOCK", "DISABLE", "restock.off");
}
}
@@ -3,8 +3,9 @@ package com.glodblock.github.inventory.item;
import static com.glodblock.github.inventory.item.WirelessMagnet.filterConfigKey;
import static com.glodblock.github.inventory.item.WirelessMagnet.filterKey;
import java.util.HashMap;
import java.util.Map;
import java.util.UUID;
import java.util.WeakHashMap;
import java.util.function.Predicate;
import net.minecraft.entity.item.EntityItem;
@@ -39,7 +40,7 @@ public class WirelessMagnetCardFilterInventory extends BaseWirelessInventory imp
private boolean useOreDict;
private String oreDictFilter = "";
protected Predicate<IAEItemStack> filterPredicate = null;
private WirelessMagnet.ListMode listMode = WirelessMagnet.ListMode.WhiteList;
private WirelessMagnet.ListMode listMode = WirelessMagnet.ListMode.BlackList;
private final AppEngInternalInventory filterInventory;
private final NBTTagCompound settingCache;
private final NBTTagCompound filterCache;
@@ -269,7 +270,7 @@ public class WirelessMagnetCardFilterInventory extends BaseWirelessInventory imp
public static class FilterCache {
private static final HashMap<UUID, WirelessMagnetCardFilterInventory> cache = new HashMap<>();
private static final Map<UUID, WirelessMagnetCardFilterInventory> cache = new WeakHashMap<>();
public static WirelessMagnetCardFilterInventory getFilter(ItemStack is, int slot, IGridNode gridNode,
EntityPlayer player) {
Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.8 KiB

After

Width:  |  Height:  |  Size: 1.5 KiB