mirror of
https://github.com/yairm210/Unciv.git
synced 2025-07-24 22:59:34 +07:00
AI will not waste promotions on Heal Instantly
This commit is contained in:
@ -158,6 +158,7 @@ object UnitAutomation {
|
||||
|
||||
if (unit.promotions.canBePromoted()) {
|
||||
val availablePromotions = unit.promotions.getAvailablePromotions()
|
||||
.filterNot { it.hasUnique(UniqueType.SkipPromotion) }
|
||||
if (availablePromotions.any())
|
||||
unit.promotions.addPromotion(availablePromotions.toList().random().name)
|
||||
}
|
||||
|
Reference in New Issue
Block a user