Skip to content

Commit

Permalink
Remove "-0 HP" from city attack notifications
Browse files Browse the repository at this point in the history
  • Loading branch information
yairm210 committed Oct 6, 2024
1 parent 604b9f1 commit 35e5a5f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion core/src/com/unciv/logic/battle/Battle.kt
Original file line number Diff line number Diff line change
Expand Up @@ -417,7 +417,7 @@ object Battle {
if (defender.isDefeated() && attacker.isRanged()) " the defence of [" + defender.getName() + "]"
else " [" + defender.getName() + "]"
else " our [" + defender.getName() + "]"
val attackerHurtString = if (damageDealt != null) " ([-${damageDealt.defenderDealt}] HP)" else ""
val attackerHurtString = if (damageDealt != null && damageDealt.defenderDealt != 0) " ([-${damageDealt.defenderDealt}] HP)" else ""
val defenderHurtString = if (damageDealt != null) " ([-${damageDealt.attackerDealt}] HP)" else ""
val notificationString = attackerString + attackerHurtString + whatHappenedString + defenderString + defenderHurtString
val attackerIcon = if (attacker is CityCombatant) NotificationIcon.City else attacker.getName()
Expand Down

0 comments on commit 35e5a5f

Please sign in to comment.