diff options
author | Bjørn Lindeijer <bjorn@lindeijer.nl> | 2005-01-17 23:30:59 +0000 |
---|---|---|
committer | Bjørn Lindeijer <bjorn@lindeijer.nl> | 2005-01-17 23:30:59 +0000 |
commit | 40e8a99139fa494f837670737c25755817b961a4 (patch) | |
tree | 54112c62a52fe744c89370a78717b828810432c6 /src | |
parent | be44b930402c7d6cc8818bb209eed8a155b25e1b (diff) | |
download | mana-client-40e8a99139fa494f837670737c25755817b961a4.tar.gz mana-client-40e8a99139fa494f837670737c25755817b961a4.tar.bz2 mana-client-40e8a99139fa494f837670737c25755817b961a4.tar.xz mana-client-40e8a99139fa494f837670737c25755817b961a4.zip |
Support for windowed in config file.
Diffstat (limited to 'src')
-rw-r--r-- | src/main.cpp | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/src/main.cpp b/src/main.cpp index 60aaf8df..df5cbeec 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -196,7 +196,14 @@ void init_engine() { SDL_WM_SetCaption("The Mana World", NULL); - screen = SDL_SetVideoMode(800, 600, 16, SDL_SWSURFACE | SDL_ANYFORMAT); + + int displayFlags = SDL_SWSURFACE | SDL_ANYFORMAT; + + if ((int)config.getValue("screen", 0)) { + displayFlags |= SDL_FULLSCREEN; + } + + screen = SDL_SetVideoMode(800, 600, 16, displayFlags); if (screen == NULL) { std::cerr << "Couldn't set 800x600x16 video mode: " << SDL_GetError() << std::endl; |