Changed the game to use true fullscreen.
The fake "windowed fullscreen" is less invasive, but it sometimes causes ugly artifacts and as a general rule isn't really all that useful. However, I also defined it in defs.h, so that it can be more easily changed in the future.
This commit is contained in:
parent
73a7afdc25
commit
e36a1e82e7
|
@ -57,6 +57,8 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
#define PATH_MAX 4096
|
#define PATH_MAX 4096
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#define FULLSCREEN SDL_WINDOW_FULLSCREEN
|
||||||
|
|
||||||
#define STARS_NUM 200
|
#define STARS_NUM 200
|
||||||
|
|
||||||
// Object Flags
|
// Object Flags
|
||||||
|
|
|
@ -250,7 +250,7 @@ void engine_setMode()
|
||||||
}
|
}
|
||||||
|
|
||||||
SDL_SetWindowIcon(window, gfx_loadImage("gfx/alienDevice.png"));
|
SDL_SetWindowIcon(window, gfx_loadImage("gfx/alienDevice.png"));
|
||||||
SDL_SetWindowFullscreen(window, engine.fullScreen ? SDL_WINDOW_FULLSCREEN_DESKTOP : 0);
|
SDL_SetWindowFullscreen(window, engine.fullScreen ? FULLSCREEN : 0);
|
||||||
|
|
||||||
renderer = SDL_CreateRenderer(window, -1, 0);
|
renderer = SDL_CreateRenderer(window, -1, 0);
|
||||||
|
|
||||||
|
|
|
@ -1173,7 +1173,7 @@ static void intermission_doOptions(SDL_Surface *optionsSurface, int x, int y)
|
||||||
{
|
{
|
||||||
if (!engine.fullScreen)
|
if (!engine.fullScreen)
|
||||||
{
|
{
|
||||||
SDL_SetWindowFullscreen(window, SDL_WINDOW_FULLSCREEN_DESKTOP);
|
SDL_SetWindowFullscreen(window, FULLSCREEN);
|
||||||
engine.fullScreen = 1;
|
engine.fullScreen = 1;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -1070,16 +1070,16 @@ void mission_showStartScreen()
|
||||||
case MISN_ELLESH:
|
case MISN_ELLESH:
|
||||||
case MISN_MARS:
|
case MISN_MARS:
|
||||||
case MISN_VENUS:
|
case MISN_VENUS:
|
||||||
screen_renderString("Phoebe Lexx will not be present", 160, screen->h / 2 + 115, FONT_WHITE);
|
screen_renderString("Phoebe Lexx will not be present", screen->w / 2 - 240, screen->h / 2 + 115, FONT_WHITE);
|
||||||
if (game.hasWingMate2)
|
if (game.hasWingMate2)
|
||||||
screen_renderString("Ursula Lexx will not be present", 160, screen->h / 2 + 145, FONT_WHITE);
|
screen_renderString("Ursula Lexx will not be present", screen->w / 2 - 240, screen->h / 2 + 145, FONT_WHITE);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
if ((game.area == MISN_URUSOR) ||
|
if ((game.area == MISN_URUSOR) ||
|
||||||
(game.area == MISN_POSWIC) ||
|
(game.area == MISN_POSWIC) ||
|
||||||
(game.area == MISN_EARTH))
|
(game.area == MISN_EARTH))
|
||||||
screen_renderString("Sid Wilson will join you on this mission", 160, screen->h / 2 + 175, FONT_WHITE);
|
screen_renderString("Sid Wilson will join you on this mission", screen->w / 2 - 240, screen->h / 2 + 175, FONT_WHITE);
|
||||||
|
|
||||||
renderer_update();
|
renderer_update();
|
||||||
}
|
}
|
||||||
|
|
|
@ -279,7 +279,7 @@ void player_getInput()
|
||||||
if (engine.keyState[KEY_FULLSCREEN])
|
if (engine.keyState[KEY_FULLSCREEN])
|
||||||
{
|
{
|
||||||
engine.fullScreen = !engine.fullScreen;
|
engine.fullScreen = !engine.fullScreen;
|
||||||
SDL_SetWindowFullscreen(window, engine.fullScreen ? SDL_WINDOW_FULLSCREEN_DESKTOP : 0);
|
SDL_SetWindowFullscreen(window, engine.fullScreen ? FULLSCREEN : 0);
|
||||||
engine.keyState[KEY_FULLSCREEN] = 0;
|
engine.keyState[KEY_FULLSCREEN] = 0;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -551,8 +551,7 @@ int title_show()
|
||||||
{
|
{
|
||||||
engine.fullScreen = !engine.fullScreen;
|
engine.fullScreen = !engine.fullScreen;
|
||||||
SDL_SetWindowFullscreen(window,
|
SDL_SetWindowFullscreen(window,
|
||||||
(engine.fullScreen ?
|
(engine.fullScreen ? FULLSCREEN : 0));
|
||||||
SDL_WINDOW_FULLSCREEN_DESKTOP : 0));
|
|
||||||
selectedOption = listLength;
|
selectedOption = listLength;
|
||||||
}
|
}
|
||||||
else if (selectedOption == 4)
|
else if (selectedOption == 4)
|
||||||
|
|
Loading…
Reference in New Issue