mirror of
https://github.com/yairm210/Unciv.git
synced 2025-07-08 23:08:35 +07:00
Move Until Healed wake up to startTurn so Fortify lasts until start of turn (#12786)
This commit is contained in:
@ -35,11 +35,6 @@ class UnitTurnManager(val unit: MapUnit) {
|
|||||||
if (!unit.hasUnitMovedThisTurn() || unit.hasUnique(UniqueType.HealsEvenAfterAction))
|
if (!unit.hasUnitMovedThisTurn() || unit.hasUnique(UniqueType.HealsEvenAfterAction))
|
||||||
healUnit()
|
healUnit()
|
||||||
|
|
||||||
if (unit.action != null && unit.health > 99)
|
|
||||||
if (unit.isActionUntilHealed()) {
|
|
||||||
unit.action = null // wake up when healed
|
|
||||||
}
|
|
||||||
|
|
||||||
if (unit.isPreparingParadrop() || unit.isPreparingAirSweep())
|
if (unit.isPreparingParadrop() || unit.isPreparingAirSweep())
|
||||||
unit.action = null
|
unit.action = null
|
||||||
|
|
||||||
@ -157,6 +152,11 @@ class UnitTurnManager(val unit: MapUnit) {
|
|||||||
}
|
}
|
||||||
) unit.action = null
|
) unit.action = null
|
||||||
|
|
||||||
|
if (unit.action != null && unit.health > 99)
|
||||||
|
if (unit.isActionUntilHealed()) {
|
||||||
|
unit.action = null // wake up when healed
|
||||||
|
}
|
||||||
|
|
||||||
val tileOwner = unit.getTile().getOwner()
|
val tileOwner = unit.getTile().getOwner()
|
||||||
if (tileOwner != null
|
if (tileOwner != null
|
||||||
&& !unit.cache.canEnterForeignTerrain
|
&& !unit.cache.canEnterForeignTerrain
|
||||||
|
Reference in New Issue
Block a user