Embarked civilian units should have no defense.

This commit is contained in:
Duan Tao 2019-03-17 15:50:52 +08:00
parent 625017f270
commit f8a8d7bbfb

View file

@ -26,7 +26,7 @@ class MapUnitCombatant(val unit: MapUnit) : ICombatant {
}
override fun getDefendingStrength(): Int {
if(unit.isEmbarked()) return 5 * getCivInfo().getEra().ordinal
if(unit.isEmbarked() && !unit.type.isCivilian()) return 5 * getCivInfo().getEra().ordinal
return unit.baseUnit().strength
}