mirror of
https://github.com/yairm210/Unciv.git
synced 2025-09-23 03:23:17 -04:00
Fix application crash when city area is too small (#2421)
This commit is contained in:
parent
9fb6ad29e5
commit
ed9fcc3ec1
@ -29,7 +29,7 @@ class CityExpansionManager {
|
||||
// (per game XML files) at 6*(t+0.4813)^1.3
|
||||
// The second seems to be more based, so I'll go with that
|
||||
fun getCultureToNextTile(): Int {
|
||||
var cultureToNextTile = 6 * (tilesClaimed() + 1.4813).pow(1.3)
|
||||
var cultureToNextTile = 6 * (kotlin.math.max(0, tilesClaimed()) + 1.4813).pow(1.3)
|
||||
if (cityInfo.civInfo.containsBuildingUnique("Cost of acquiring new tiles reduced by 25%"))
|
||||
cultureToNextTile *= 0.75 //Speciality of Angkor Wat
|
||||
if(cityInfo.containsBuildingUnique("Culture and Gold costs of acquiring new tiles reduced by 25% in this city"))
|
||||
|
Loading…
x
Reference in New Issue
Block a user