mirror of
https://github.com/yairm210/Unciv.git
synced 2025-03-09 04:09:35 +07:00
commit
19a78587de
@ -49,8 +49,9 @@ class BattleDamage{
|
||||
if (combatant.getCivInfo().happiness < 0)
|
||||
modifiers["Unhappiness"] = max(0.02f * combatant.getCivInfo().happiness,-0.9f) // otherwise it could exceed -100% and start healing enemy units...
|
||||
|
||||
if(combatant.getCivInfo().policies.isAdopted("Populism"))
|
||||
if(combatant.getCivInfo().policies.isAdopted("Populism") && combatant.getHealth() < 100){
|
||||
modifiers["Populism"] = 0.25f
|
||||
}
|
||||
|
||||
if(combatant.getCivInfo().policies.isAdopted("Discipline") && combatant.isMelee()
|
||||
&& combatant.getTile().neighbors.flatMap { it.getUnits() }
|
||||
@ -215,4 +216,4 @@ class BattleDamage{
|
||||
val ratio = getAttackingStrength(attacker,defender) / getDefendingStrength(attacker,defender)
|
||||
return (ratio * 30 * getHealthDependantDamageRatio(attacker)).toInt()
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user