mirror of
https://github.com/yairm210/Unciv.git
synced 2025-09-22 02:42:16 -04:00
Ranged units don't get damaged when attacking
This commit is contained in:
parent
4de9ee106f
commit
abaf39a15c
@ -53,6 +53,7 @@ class Battle(val gameInfo:GameInfo) {
|
||||
}
|
||||
|
||||
fun calculateDamageToAttacker(attacker: ICombatant, defender: ICombatant): Int {
|
||||
if(attacker.getCombatantType() == CombatantType.Ranged) return 0
|
||||
return (getDefendingStrength(attacker,defender) * 50 / getAttackingStrength(attacker,defender)).toInt()
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user