@@ -1122,25 +1122,25 @@ static bool FlowRiver(bool *marks, TileI
TileIndex t2 = end + TileOffsByDiagDir(d);
if (IsValidTile(t2) && !marks[t2] && FlowsDown(end, t2)) {
marks[t2] = true;
count++;
queue.push_back(t2);
}
} while (!queue.empty());
if (found) {
/* Flow further down hill. */
found = FlowRiver(marks, spring, end);
} else if (count > 10) {
} else if (count > 32) {
/* Maybe we can make a lake. Find the Nth of the considered tiles. */
TileIndex lakeCenter = 0;
for (int i = RandomRange(count - 1); i != 0; lakeCenter++) {
if (marks[lakeCenter]) i--;
if (IsValidTile(lakeCenter) &&
/* A river, or lake, can only be built on flat slopes. */
GetTileSlope(lakeCenter, NULL) == SLOPE_FLAT &&
/* We want the lake to be built at the height of the river. */
TileHeight(begin) == TileHeight(lakeCenter) &&
/* We don't want the lake at the entry of the valley. */
Status change: