From afba3200835fe2ea08140911f1194f64ddd43ffe Mon Sep 17 00:00:00 2001 From: Misa Date: Wed, 13 Jan 2021 22:35:41 -0800 Subject: [PATCH] Remove duplicate graphics.Makebfont() in main() This call to Makebfont() always existed, but ever since 2.3's per-level custom assets were added, graphics.reloadresources() also calls graphics.Makebfont(), meaning this call is unnecessary. Calling it twice results in graphics.bfont and graphics.flipbfont having twice the number of elements, until custom assets get mounted (or unmounted, technically). --- desktop_version/src/main.cpp | 2 -- 1 file changed, 2 deletions(-) diff --git a/desktop_version/src/main.cpp b/desktop_version/src/main.cpp index ae0db7c5..2695b627 100644 --- a/desktop_version/src/main.cpp +++ b/desktop_version/src/main.cpp @@ -265,8 +265,6 @@ int main(int argc, char *argv[]) SDL_SetSurfaceBlendMode(graphics.ghostbuffer, SDL_BLENDMODE_BLEND); SDL_SetSurfaceAlphaMod(graphics.ghostbuffer, 127); - graphics.Makebfont(); - graphics.foregroundBuffer = CREATE_SURFACE(320, 240); SDL_SetSurfaceBlendMode(graphics.foregroundBuffer, SDL_BLENDMODE_BLEND);