Resolved #5469 - 'tile to expand to' choice incorporates city-specific bonuses

This commit is contained in:
yairm210 2021-12-28 22:36:30 +02:00
parent e3fb00d939
commit 66fa8db51c

View File

@ -283,7 +283,6 @@ object Automation {
if (tile.hasViewableResource(cityInfo.civInfo)) {
if (tile.tileResource.resourceType != ResourceType.Bonus) score -= 105
else if (distance <= 3) score -= 104
} else {
// Water tiles without resources aren't great
if (tile.isWater) score += 25
@ -296,13 +295,10 @@ object Automation {
tile.getImprovementStats(tile.getTileImprovement()!!, cityInfo.civInfo, cityInfo).values.sum() > 0f
) score -= 5
// The original checks if the tile has a road, but adds a score of 0 if it does.
// Therefore, this check is removed here.
if (tile.naturalWonder != null) score -= 105
// Straight up take the sum of all yields
score -= tile.getTileStats(null, cityInfo.civInfo).values.sum().toInt()
score -= tile.getTileStats(cityInfo, cityInfo.civInfo).values.sum().toInt()
// Check if we get access to better tiles from this tile
var adjacentNaturalWonder = false