diff --git a/OpenRA.Game/Traits/Submarine.cs b/OpenRA.Game/Traits/Submarine.cs index 7dfcbcf95e..c9cb9528bb 100644 --- a/OpenRA.Game/Traits/Submarine.cs +++ b/OpenRA.Game/Traits/Submarine.cs @@ -20,6 +20,7 @@ using System.Collections.Generic; using System.Linq; +using System; namespace OpenRA.Traits { @@ -49,7 +50,7 @@ namespace OpenRA.Traits if (remainingTime <= 0) OnSurface(); - remainingTime = (int)(self.Info.Traits.Get().CloakDelay * 25); + remainingTime = Math.Max(remainingTime, (int)(self.Info.Traits.Get().CloakDelay * 25)); } public void Attacking(Actor self) { DoSurface(); }