From aafb01ab331ca620a7fe8fc5a36bbc362c99066c Mon Sep 17 00:00:00 2001 From: hendricks266 Date: Fri, 8 Jan 2016 01:32:50 +0000 Subject: [PATCH] Move loading of settings.cfg to before video init so that it can respect r_togglecomposition. git-svn-id: https://svn.eduke32.com/eduke32@5518 1a8010ca-5511-0410-912e-c29ae57300e0 --- polymer/eduke32/source/game.c | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/polymer/eduke32/source/game.c b/polymer/eduke32/source/game.c index f5c91e84a..d9d5be852 100644 --- a/polymer/eduke32/source/game.c +++ b/polymer/eduke32/source/game.c @@ -11902,6 +11902,16 @@ int32_t app_main(int32_t argc, const char **argv) system_getcvars(); + char *ptr = Xstrdup(setupfilename), *p = strtok(ptr, "."); + + if (!Bstrcmp(setupfilename, SETUPFILENAME)) + Bsprintf(tempbuf, "settings.cfg"); + else + Bsprintf(tempbuf, "%s_settings.cfg", p); + + OSD_Exec(tempbuf); + Bfree(ptr); + if (g_networkMode != NET_DEDICATED_SERVER) { if (setgamemode(ud.config.ScreenMode,ud.config.ScreenWidth,ud.config.ScreenHeight,ud.config.ScreenBPP) < 0) @@ -11948,16 +11958,6 @@ int32_t app_main(int32_t argc, const char **argv) } // loadtmb(); - char *ptr = Xstrdup(setupfilename), *p = strtok(ptr, "."); - - if (!Bstrcmp(setupfilename, SETUPFILENAME)) - Bsprintf(tempbuf, "settings.cfg"); - else - Bsprintf(tempbuf, "%s_settings.cfg", p); - - OSD_Exec(tempbuf); - Bfree(ptr); - OSD_Exec("autoexec.cfg"); M_Init();