try to not void fluids in fluid terminal when running out of power

This commit is contained in:
Salomão
2021-06-17 23:32:16 -03:00
parent 0fb393820b
commit eab695b692
3 changed files with 7 additions and 3 deletions
@@ -157,7 +157,7 @@ public class AppEngSlot extends Slot
{
if( this.isSlotEnabled() )
{
return !this.itemHandler.extractItem( this.index, 1, true ).isEmpty();
return !this.itemHandler.extractItem( this.index, Integer.MAX_VALUE, true ).isEmpty();
}
return false;
}
@@ -175,7 +175,7 @@ public class ApiStorage implements IStorageHelper
@Override
public int transferFactor()
{
return 125;
return 1000;
}
@Override
@@ -446,7 +446,11 @@ public class ContainerFluidTerminal extends AEBaseContainer implements IConfigMa
if( notInserted != null && notInserted.getStackSize() > 0 )
{
AELog.error( "Fluid item [%s] reported a different possible amount to drain than it actually provided.", held.getDisplayName() );
IAEFluidStack spill = this.monitor.injectItems( notInserted, Actionable.MODULATE, this.getActionSource() );
if( spill != null && spill.getStackSize() > 0 )
{
fh.fill( spill.getFluidStack(), true );
}
}
player.inventory.setItemStack( fh.getContainer() );