Denounce now has a confirmation popup

This commit is contained in:
Yair Morgenstern 2020-08-10 23:24:02 +03:00
parent 3b2e813523
commit 889d6a1587
2 changed files with 5 additions and 2 deletions

View File

@ -72,6 +72,7 @@ We have encountered the City-State of [name]! =
Declare Friendship ([numberOfTurns] turns) = Declare Friendship ([numberOfTurns] turns) =
May our nations forever remain united! = May our nations forever remain united! =
Indeed! = Indeed! =
Denounce [civName]? =
Denounce ([numberOfTurns] turns) = Denounce ([numberOfTurns] turns) =
We will remember this. = We will remember this. =

View File

@ -251,8 +251,10 @@ class DiplomacyScreen(val viewingCiv:CivilizationInfo):CameraStageBaseScreen() {
&& !diplomacyManager.hasFlag(DiplomacyFlags.DeclarationOfFriendship)) { && !diplomacyManager.hasFlag(DiplomacyFlags.DeclarationOfFriendship)) {
val denounceButton = "Denounce ([30] turns)".toTextButton() val denounceButton = "Denounce ([30] turns)".toTextButton()
denounceButton.onClick { denounceButton.onClick {
diplomacyManager.denounce() YesNoPopup("Denounce [${otherCiv.civName}]?", {
setRightSideFlavorText(otherCiv, "We will remember this.", "Very well.") diplomacyManager.denounce()
setRightSideFlavorText(otherCiv, "We will remember this.", "Very well.")
}, this).open()
} }
diplomacyTable.add(denounceButton).row() diplomacyTable.add(denounceButton).row()
if (isNotPlayersTurn()) denounceButton.disable() if (isNotPlayersTurn()) denounceButton.disable()