Units that can move after attacking (horseman, knight) no longer get deducted movement points for BOTH the movement to the enemy tile AND the attack
This commit is contained in:
parent
02c74ad8ba
commit
9aa41d3d13
1 changed files with 4 additions and 2 deletions
|
@ -170,8 +170,10 @@ class Battle(val gameInfo:GameInfo=UnCivGame.Current.gameInfo) {
|
|||
}
|
||||
|
||||
if(attacker is MapUnitCombatant) {
|
||||
if (attacker.unit.hasUnique("Can move after attacking"))
|
||||
attacker.unit.currentMovement = max(0f, attacker.unit.currentMovement - 1)
|
||||
if (attacker.unit.hasUnique("Can move after attacking")){
|
||||
if(!attacker.getUnitType().isMelee() || !defender.isDefeated()) // if it was a melee attack and we won, then the unit ALREADY got movement points deducted, for the movement to the enemie's tile!
|
||||
attacker.unit.currentMovement = max(0f, attacker.unit.currentMovement - 1)
|
||||
}
|
||||
else attacker.unit.currentMovement = 0f
|
||||
attacker.unit.attacksThisTurn+=1
|
||||
attacker.unit.action=null // for instance, if it was fortified
|
||||
|
|
Loading…
Reference in a new issue