int getEstimatedShipsOnPlanet(PlanetData planetData, int futureInDays) { int shipsOnPlanetAtArrivalday = Math.Min(planetData.Ships + planetData.GetActualFactorySpeed() * futureInDays, Math.Max(planetData.Ships, planetData.HangarSize)); //shipsOnPlanetAtArrivalday is the maximum number of ships that can be expected if the planet does not receive additional supplies return shipsOnPlanetAtArrivalday; }