File tree Expand file tree Collapse file tree 1 file changed +4
-0
lines changed
src/main/java/mekanism/common/inventory/slot Expand file tree Collapse file tree 1 file changed +4
-0
lines changed Original file line number Diff line number Diff line change @@ -128,6 +128,10 @@ default void drainTank(IInventorySlot outputSlot) {
128128 //Fill the stack, note our stack is a copy so this is how we simulate to get the proper "container" item,
129129 // and it does not actually matter that we are directly executing on the item
130130 int toDrain = fluidHandlerItem .fill (fluidInTank , FluidAction .EXECUTE );
131+ if (toDrain == 0 ) {
132+ //If we cannot actually fill the item then just exit early
133+ return ;
134+ }
131135 if (getCount () == 1 ) {
132136 IFluidHandlerItem containerCap = Capabilities .FLUID .getCapability (fluidHandlerItem .getContainer ());
133137 if (containerCap != null && containerCap .fill (fluidInTank , FluidAction .SIMULATE ) > 0 ) {
You can’t perform that action at this time.
0 commit comments