From b8d7c85ba388674471d411ab2f02ade0d2872cf2 Mon Sep 17 00:00:00 2001 From: Zorbatron Date: Thu, 19 Sep 2024 16:06:18 -0400 Subject: [PATCH] Fix reservoir hatch input slot filtering --- .../multiblockpart/MetaTileEntityReservoirHatch.java | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/src/main/java/gregtech/common/metatileentities/multi/multiblockpart/MetaTileEntityReservoirHatch.java b/src/main/java/gregtech/common/metatileentities/multi/multiblockpart/MetaTileEntityReservoirHatch.java index 9c0a078f34f..05c61769392 100644 --- a/src/main/java/gregtech/common/metatileentities/multi/multiblockpart/MetaTileEntityReservoirHatch.java +++ b/src/main/java/gregtech/common/metatileentities/multi/multiblockpart/MetaTileEntityReservoirHatch.java @@ -131,6 +131,7 @@ public boolean usesMui2() { public ModularPanel buildUI(PosGuiData guiData, PanelSyncManager guiSyncManager) { guiSyncManager.registerSlotGroup("item_inv", 2); + // TODO: Use controlsAmount(false) in the sync handler when #2622 is done GTFluidSyncHandler tankSyncHandler = new GTFluidSyncHandler(this.fluidTank) .canDrainSlot(true).canFillSlot(false); @@ -151,16 +152,11 @@ public ModularPanel buildUI(PosGuiData guiData, PanelSyncManager guiSyncManager) .child(IKey.dynamic(() -> getFluidNameTranslated(tankSyncHandler)) .color(0xFFFFFF) .asWidget().pos(11, 40)) - // TODO: Use controlsAmount(false) in the sync handler when #2622 is done .child(new GTFluidSlot().syncHandler(tankSyncHandler) .pos(69, 52)) .child(new ItemSlot().slot(SyncHandlers.itemSlot(this.importItems, 0) .slotGroup("item_inv") - .filter(itemStack -> { - IFluidHandlerItem fluidHandlerItem = FluidUtil.getFluidHandler(itemStack); - return fluidHandlerItem != null && - fluidHandlerItem.getTankProperties()[0].getContents() != null; - })) + .filter(itemStack -> FluidUtil.getFluidHandler(itemStack) != null)) .background(GTGuiTextures.SLOT, GTGuiTextures.IN_SLOT_OVERLAY) .pos(90, 16)) .child(new ItemSlot().slot(SyncHandlers.itemSlot(this.exportItems, 0)