1
0
mirror of https://github.com/vcmi/vcmi.git synced 2025-03-27 21:49:10 +02:00

Don't place shipyard or boats at very small lakes

(cherry picked from commit 1d2913bea0fb5029fd1e8843d8aedd62560c8d4e)
This commit is contained in:
Tomasz Zieliński 2023-03-18 21:48:17 +01:00
parent d9fac6d6fb
commit dd3803b111

View File

@ -142,6 +142,13 @@ RouteInfo WaterProxy::waterRoute(Zone & dst)
dst.areaPossible().subtract(lake.neighbourZones[dst.getId()]);
continue;
}
//Don't place shipyard or boats on the very small lake
if (lake.area.getTiles().size() < 25)
{
logGlobal->info("Skipping very small lake at zone %d", dst.getId());
continue;
}
int zoneTowns = 0;
if(auto * m = dst.getModificator<TownPlacer>())