mirror of
https://github.com/yairm210/Unciv.git
synced 2025-01-07 14:02:48 +07:00
Added notification for destruction of tile improvements [via unit ability] (#9754)
* Added notification for desctruction of tile improvements [via unit ability] * Modified template properties * Update template.properties
This commit is contained in:
parent
3c56319640
commit
8f761642f6
@ -916,6 +916,7 @@ Our [interceptorName] ([amount] HP) intercepted and attacked an enemy [attackerN
|
|||||||
Nothing tried to intercept our [attackerName] =
|
Nothing tried to intercept our [attackerName] =
|
||||||
An enemy [unit] was spotted near our territory =
|
An enemy [unit] was spotted near our territory =
|
||||||
An enemy [unit] was spotted in our territory =
|
An enemy [unit] was spotted in our territory =
|
||||||
|
An enemy [unit] has destroyed our tile improvement [improvement] =
|
||||||
Your city [cityName] can bombard the enemy! =
|
Your city [cityName] can bombard the enemy! =
|
||||||
[amount] of your cities can bombard the enemy! =
|
[amount] of your cities can bombard the enemy! =
|
||||||
[amount] enemy units were spotted near our territory =
|
[amount] enemy units were spotted near our territory =
|
||||||
|
@ -1164,7 +1164,13 @@ object Battle {
|
|||||||
if (!attackedTile.getTileImprovement()!!.hasUnique(UniqueType.Unpillagable)
|
if (!attackedTile.getTileImprovement()!!.hasUnique(UniqueType.Unpillagable)
|
||||||
&& attacker.hasUnique(UniqueType.DestroysImprovementUponAttack, conditionalState)
|
&& attacker.hasUnique(UniqueType.DestroysImprovementUponAttack, conditionalState)
|
||||||
) {
|
) {
|
||||||
|
val currentTileImprovement = attackedTile.improvement
|
||||||
attackedTile.changeImprovement(null)
|
attackedTile.changeImprovement(null)
|
||||||
|
defender.getCivInfo().addNotification(
|
||||||
|
"An enemy [${attacker.unit.baseUnit.name}] has destroyed our tile improvement [${currentTileImprovement}]",
|
||||||
|
LocationAction(attackedTile.position, attacker.getTile().position),
|
||||||
|
NotificationCategory.War, attacker.unit.baseUnit.name,
|
||||||
|
NotificationIcon.War)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user