Resolves #9988 - modded units can construct improvements on impassible tiles

This commit is contained in:
Yair Morgenstern 2024-03-17 08:54:16 +02:00
parent 618cffcd23
commit 3af0d2c3b3

View File

@ -18,7 +18,6 @@ import com.unciv.models.ruleset.unique.UniqueTarget
import com.unciv.models.ruleset.unique.UniqueTriggerActivation
import com.unciv.models.ruleset.unique.UniqueType
import com.unciv.models.stats.Stat
import com.unciv.models.stats.Stats
import com.unciv.models.translations.fillPlaceholders
import com.unciv.models.translations.removeConditionals
import com.unciv.models.translations.tr
@ -300,7 +299,6 @@ object UnitActionsFromUniques {
// Next test is to prevent interfering with UniqueType.CreatesOneImprovement -
// not pretty, but users *can* remove the building from the city queue an thus clear this:
&& !tile.isMarkedForCreatesOneImprovement()
&& !tile.isImpassible() // Not 100% sure that this check is necessary...
&& UnitActionModifiers.canActivateSideEffects(unit, unique)
}
))