mirror of
https://github.com/yairm210/Unciv.git
synced 2025-07-04 15:27:50 +07:00
Resolved #8088 - Single turn repair, repair turn inconsistencies
This commit is contained in:
@ -533,16 +533,8 @@ object UnitActions {
|
||||
return {
|
||||
unit.currentMovement = 0f
|
||||
val tile = unit.currentTile
|
||||
val repairTurns = getRepairTurns(unit) - 1
|
||||
if (repairTurns == 0) { // handle instant fix
|
||||
tile.setRepaired()
|
||||
unit.civInfo.updateDetailedCivResources() // maybe just restored a resource
|
||||
unit.civInfo.transients()
|
||||
.updateCitiesConnectedToCapital() // check for connections to capital
|
||||
} else {
|
||||
tile.improvementInProgress = Constants.repair
|
||||
tile.turnsToImprovement = repairTurns
|
||||
}
|
||||
tile.improvementInProgress = Constants.repair
|
||||
tile.turnsToImprovement = getRepairTurns(unit)
|
||||
}
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user