4.5.0-patch3

Fixed 'unitsToRemove' error
This commit is contained in:
Yair Morgenstern
2023-02-26 10:13:25 +02:00
parent 8e17c9ed98
commit cff8876ec8
2 changed files with 3 additions and 3 deletions

View File

@ -3,8 +3,8 @@ package com.unciv.build
object BuildConfig {
const val kotlinVersion = "1.8.0"
const val appName = "Unciv"
const val appCodeNumber = 821
const val appVersion = "4.5.0-patch2"
const val appCodeNumber = 822
const val appVersion = "4.5.0-patch3"
const val gdxVersion = "1.11.0"
const val roboVMVersion = "2.3.1"

View File

@ -162,7 +162,7 @@ class Ruleset {
cityStateTypes.putAll(ruleset.cityStateTypes)
ruleset.modOptions.unitsToRemove
.flatMap { unitToRemove ->
units.filter { it.value.matchesFilter(unitToRemove) }.keys
units.filter { it.apply { value.ruleset=this@Ruleset }.value.matchesFilter(unitToRemove) }.keys
}.toSet().forEach {
units.remove(it)
}