From e9351b4a005e0a98a28c3977a6a6e55fb68dacef Mon Sep 17 00:00:00 2001 From: Misa Date: Sat, 25 Sep 2021 17:06:59 -0700 Subject: [PATCH] Fix winning in No Death Mode saying "One trinkets" While dying in No Death Mode was fixed to no longer say "One trinkets" in 2.3, if you win in No Death Mode with one trinket, the game would say "One trinkets". So to fix this, just slot a ternary in there. The code is already kind of bad anyways and is going to be refactored/de-STLed in the future regardless, so I'm not feeling too badly about shoving a ternary in there like that. --- desktop_version/src/Render.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/desktop_version/src/Render.cpp b/desktop_version/src/Render.cpp index 17bfd064..96ca1ba0 100644 --- a/desktop_version/src/Render.cpp +++ b/desktop_version/src/Render.cpp @@ -978,7 +978,7 @@ static void menurender(void) std::string tempstring = "You rescued all the crewmates!"; graphics.Print(0, 100, tempstring, tr, tg, tb, true); - tempstring = "And you found " + help.number_words(game.ndmresulttrinkets) + " trinkets."; + tempstring = "And you found " + help.number_words(game.ndmresulttrinkets) + " trinket" + (game.ndmresulttrinkets == 1 ? "" : "s") + "."; graphics.Print(0, 110, tempstring, tr, tg, tb, true); graphics.Print(0, 160, "A new trophy has been awarded and", tr, tg, tb, true);