(a1fe45652) Add some margin.

This commit is contained in:
Joonas Rikkonen
2019-05-16 05:18:01 +03:00
parent cbfef49e9d
commit f61bff8970
10 changed files with 106 additions and 302 deletions
@@ -34,12 +34,12 @@ namespace Barotrauma
if (character.Submarine != null && !character.Submarine.IsEntityFoundOnThisSub(pump.Item, true)) { return false; }
if (Option == "stoppumping")
{
if (!pump.IsActive || pump.FlowPercentage == 0.0f) { return false; }
if (!pump.IsActive || MathUtils.NearlyEqual(pump.FlowPercentage, 0)) { return false; }
}
else
{
if (!pump.Item.InWater) { return false; }
if (pump.IsActive && pump.FlowPercentage <= -100.0f) { return false; }
if (pump.IsActive && pump.FlowPercentage <= -99.9f) { return false; }
}
return true;
}