mirror of
https://github.com/yairm210/Unciv.git
synced 2025-07-23 14:19:15 +07:00
Resolved #12308 - Wait action selects next unit
This commit is contained in:
@ -381,8 +381,7 @@ object UnitActions {
|
|||||||
type = UnitActionType.Wait,
|
type = UnitActionType.Wait,
|
||||||
useFrequency = 65f, // Preferably have this on the first page
|
useFrequency = 65f, // Preferably have this on the first page
|
||||||
action = {
|
action = {
|
||||||
unit.due = false
|
unit.due = false // Skips to next unit due to worldScreen.switchToNextUnit() in activateAction
|
||||||
GUI.getWorldScreen().switchToNextUnit()
|
|
||||||
}
|
}
|
||||||
))
|
))
|
||||||
}
|
}
|
||||||
|
@ -179,7 +179,8 @@ class UnitActionsTable(val worldScreen: WorldScreen) : Table() {
|
|||||||
// overlay, since the user definitely wants to interact with the new unit.
|
// overlay, since the user definitely wants to interact with the new unit.
|
||||||
worldScreen.mapHolder.removeUnitActionOverlay()
|
worldScreen.mapHolder.removeUnitActionOverlay()
|
||||||
if (!UncivGame.Current.settings.autoUnitCycle) return
|
if (!UncivGame.Current.settings.autoUnitCycle) return
|
||||||
if (unit.isDestroyed || unitAction.type.isSkippingToNextUnit && (unit.isMoving() && !unit.hasMovement() || !unit.isMoving()))
|
if (unit.isDestroyed ||
|
||||||
|
unitAction.type.isSkippingToNextUnit && (!unit.isMoving() || !unit.hasMovement()))
|
||||||
worldScreen.switchToNextUnit()
|
worldScreen.switchToNextUnit()
|
||||||
else worldScreen.bottomUnitTable.selectedUnitHasChanged = true
|
else worldScreen.bottomUnitTable.selectedUnitHasChanged = true
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user