This commit is contained in:
DepressedTWM 2026-05-27 17:12:56 +04:00
parent c3b0565714
commit e519c5a9ef

View file

@ -218,15 +218,6 @@ static void setGamePathInRegistry() {
}
int main(int argc, char *argv[]){
char msg[512];
/* now we load the config */
Config conf;
conf.read(argc, argv);
#if defined WIN32
if(conf.Windows_AllocConsole == true){
}
#endif
loadLanguageMetadata(); //there will be a segfault on fclose if I don't move it here
SDL_SetHint(SDL_HINT_VIDEO_MINIMIZE_ON_FOCUS_LOSS, "0");
@ -276,6 +267,15 @@ int main(int argc, char *argv[]){
/* Initialize physfs here so that config can call PHYSFS_getPrefDir */
PHYSFS_init(argv[0]);
/* now we load the config */
Config conf;
conf.read(argc, argv);
#if defined WIN32
if(conf.Windows_AllocConsole == true){
}
#endif
if (!conf.gameFolder.empty())
if (chdir(conf.gameFolder.c_str()) != 0){
showInitError(std::string("Unable to switch into gameFolder ") + conf.gameFolder);