From 32e14755dd7c30b8563211ccb3517d1ba3aaa0da Mon Sep 17 00:00:00 2001 From: Dav999-v Date: Sat, 25 Feb 2023 03:39:59 +0100 Subject: [PATCH] Fix centering of translated "Level Complete!" and "Game Complete!" Operator precedence meant that `sc == 2 ? PR_2X : PR_1X | PR_CEN` didn't work how I expected it to. So I added some parentheses. --- desktop_version/src/Graphics.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/desktop_version/src/Graphics.cpp b/desktop_version/src/Graphics.cpp index f8838e8f..5e94a2c8 100644 --- a/desktop_version/src/Graphics.cpp +++ b/desktop_version/src/Graphics.cpp @@ -881,7 +881,7 @@ void Graphics::drawgui(void) { y = 240 - y - 8*sc; } - font::print(sc==2 ? PR_2X : PR_1X | PR_CEN, -1, y, translation, 164, 164, 255); + font::print((sc==2 ? PR_2X : PR_1X) | PR_CEN, -1, y, translation, 164, 164, 255); } else { @@ -917,7 +917,7 @@ void Graphics::drawgui(void) { y = 240 - y - 8*sc; } - font::print(sc==2 ? PR_2X : PR_1X | PR_CEN, -1, y, translation, 196, 196, 243); + font::print((sc==2 ? PR_2X : PR_1X) | PR_CEN, -1, y, translation, 196, 196, 243); } else {