diff --git a/src/main/java/com/glodblock/github/inventory/FluidConvertingInventoryAdaptor.java b/src/main/java/com/glodblock/github/inventory/FluidConvertingInventoryAdaptor.java index 32ad5da8b..7075487da 100644 --- a/src/main/java/com/glodblock/github/inventory/FluidConvertingInventoryAdaptor.java +++ b/src/main/java/com/glodblock/github/inventory/FluidConvertingInventoryAdaptor.java @@ -31,7 +31,9 @@ import appeng.api.config.FuzzyMode; import appeng.api.config.InsertionMode; +import appeng.api.config.Settings; import appeng.api.config.Upgrades; +import appeng.api.config.YesNo; import appeng.api.parts.IPart; import appeng.helpers.DualityInterface; import appeng.helpers.IInterfaceHost; @@ -99,11 +101,18 @@ public static InventoryAdaptor wrap(TileEntity capProvider, ForgeDirection face) || Util.getPart(inter, face.getOpposite()) instanceof PartFluidExportBus || Util.getPart(inter, face.getOpposite()) instanceof PartFluidP2PInterface)) return InventoryAdaptor.getAdaptor(capProvider, face); + if (InventoryAdaptor.getAdaptor(capProvider, face) == null) { + if (capProvider instanceof IFluidHandler tank) { + if (!(tank.getTankInfo(face).length > 0)) return null; + } else { + return null; + } + } InventoryAdaptor item = InventoryAdaptor.getAdaptor(capProvider, face); IFluidHandler fluid = capProvider instanceof IFluidHandler ? (IFluidHandler) capProvider : null; boolean onmi = false; - if (inter instanceof TileInterface) { - onmi = ((TileInterface) inter).getTargets().size() > 1; + if (inter instanceof TileInterface in) { + if (in.getConfigManager().getSetting(Settings.BLOCK) == YesNo.NO) onmi = in.getTargets().size() > 1; } return new FluidConvertingInventoryAdaptor(capProvider, item, fluid, face, new BlockPos(inter), onmi); }