From: TheSaminator Date: Wed, 8 Jun 2022 15:40:23 +0000 (-0400) Subject: Fix subplot victory titles X-Git-Url: https://gitweb.starshipfights.net/?a=commitdiff_plain;h=32f5303ab9d5309d97b0a84bbd3e379bcf05a0a5;p=starship-fights Fix subplot victory titles --- diff --git a/src/commonMain/kotlin/starshipfights/game/game_subplots.kt b/src/commonMain/kotlin/starshipfights/game/game_subplots.kt index 8b41938..6d68742 100644 --- a/src/commonMain/kotlin/starshipfights/game/game_subplots.kt +++ b/src/commonMain/kotlin/starshipfights/game/game_subplots.kt @@ -271,7 +271,7 @@ fun victoryTitle(player: GlobalSide, winner: GlobalSide?, subplotOutcomes: Map { val isGlorious = myOutcomes.all { (_, outcome) -> outcome == SubplotOutcome.WON } - val isPyrrhic = myOutcomes.size >= 2 && myOutcomes.any { (_, outcome) -> outcome != SubplotOutcome.WON } + val isPyrrhic = myOutcomes.size >= 2 && myOutcomes.none { (_, outcome) -> outcome == SubplotOutcome.WON } if (isGlorious) "Glorious Victory" @@ -282,7 +282,7 @@ fun victoryTitle(player: GlobalSide, winner: GlobalSide?, subplotOutcomes: Map { val isHeroic = myOutcomes.all { (_, outcome) -> outcome == SubplotOutcome.WON } - val isHumiliating = myOutcomes.size >= 2 && myOutcomes.any { (_, outcome) -> outcome != SubplotOutcome.WON } + val isHumiliating = myOutcomes.size >= 2 && myOutcomes.none { (_, outcome) -> outcome == SubplotOutcome.WON } if (isHeroic) "Heroic Defeat"