@Override
public int fill(ForgeDirection from, FluidStack resource, boolean doFill) {
if (!canFill(from, null))
return 0;
if (resource == null || resource.amount <= 0) return 0;
TankManager tMan = getTankManager();
if (tMan == null)
return 0;
resource = resource.copy();
resource.amount = Math.min(resource.amount, FLOW_RATE);
int filled = tMan.fill(0, resource, doFill);
if (filled > 0 && doFill)
setFilling(resource.copy());
return filled;
}