Change video color depth from game options

This commit is contained in:
pelya
2016-04-17 00:30:13 +03:00
committed by Sergii Pylypenko
parent 7252c08e50
commit 8d0391bf9c
6 changed files with 66 additions and 6 deletions

View File

@@ -33,6 +33,7 @@
#include "tilehighlight_func.h"
#include "hotkeys.h"
#include "tutorial_gui.h"
#include "gui.h"
#include "saveload/saveload.h"
@@ -565,6 +566,12 @@ void SetupColoursAndInitialWindow()
case GM_MENU:
ShowSelectGameWindow();
ShowTutorialWindowOnceAfterInstall();
if (getenv("SDL_RESTART_PARAMS") != NULL) {
static int counter = 5; // This part of code is called several times during startup, which closes all windows, so we need to put random hacks here
counter--;
ShowGameOptions();
if (counter == 0) unsetenv("SDL_RESTART_PARAMS");
}
break;
case GM_NORMAL: