mirror of
https://github.com/yairm210/Unciv.git
synced 2025-07-05 07:49:17 +07:00
Resolved #5713 - AI doesn't try attacking with non-attack units
This commit is contained in:
@ -129,7 +129,7 @@ object UnitAutomation {
|
|||||||
// Might die next turn - move!
|
// Might die next turn - move!
|
||||||
if (unit.health <= unit.getDamageFromTerrain() && tryHealUnit(unit)) return
|
if (unit.health <= unit.getDamageFromTerrain() && tryHealUnit(unit)) return
|
||||||
|
|
||||||
if (unit.isCivilian()) {
|
if (unit.isCivilian() || unit.hasUnique(UniqueType.CannotAttack)) {
|
||||||
if (tryRunAwayIfNeccessary(unit)) return
|
if (tryRunAwayIfNeccessary(unit)) return
|
||||||
|
|
||||||
if (unit.hasUnique(UniqueType.FoundCity))
|
if (unit.hasUnique(UniqueType.FoundCity))
|
||||||
|
Reference in New Issue
Block a user