Fixed pillaged improvement defence bonus (#8593)

* Fixed pillaged improvement defence bonus

* Fix
This commit is contained in:
Gualdimar 2023-02-06 16:41:30 +02:00 committed by GitHub
parent c171376479
commit d73814263f
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -544,7 +544,7 @@ open class Tile : IsPartOfGameInfoSerialization {
if (otherTerrainBonus != 0f) bonus = otherTerrainBonus // replaces baseTerrainObject
}
if (naturalWonder != null) bonus += getNaturalWonder().defenceBonus
val tileImprovement = getTileImprovement()
val tileImprovement = getUnpillagedTileImprovement()
if (tileImprovement != null) {
for (unique in tileImprovement.getMatchingUniques(UniqueType.DefensiveBonus, StateForConditionals(tile = this)))
bonus += unique.params[0].toFloat() / 100