Fix cockpit switch in SDL-only build
The cockpit graphic is not scaled in the SDL build, so it is only meaningful to show when the game window dimensions match the graphic's dimensions. Prior to4a8d7c7574
, this worked, because the `initial_large_game_screen_mode` was the same as the graphic's dimensions. That commit changed `initial_large_game_screen_mode` to prefer a larger screen resolution for new users. It should have retained the original dimensions for this test. Make that change here. Fixes:4a8d7c7574
("Default to 1024x768 for new users, not 640x480")
This commit is contained in:
parent
7effca68f0
commit
16c86edabc
|
@ -197,9 +197,6 @@ void reset_palette_add()
|
||||||
PaletteBlueAdd = 0;
|
PaletteBlueAdd = 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
#if !DXX_USE_OGL
|
|
||||||
constexpr screen_mode initial_small_game_screen_mode{320, 200};
|
|
||||||
#endif
|
|
||||||
constexpr screen_mode initial_large_game_screen_mode{1024, 768};
|
constexpr screen_mode initial_large_game_screen_mode{1024, 768};
|
||||||
screen_mode Game_screen_mode = initial_large_game_screen_mode;
|
screen_mode Game_screen_mode = initial_large_game_screen_mode;
|
||||||
|
|
||||||
|
@ -267,7 +264,9 @@ void init_cockpit()
|
||||||
#if defined(DXX_BUILD_DESCENT_II)
|
#if defined(DXX_BUILD_DESCENT_II)
|
||||||
int HiresGFXAvailable = !GameArg.GfxSkipHiresGFX;
|
int HiresGFXAvailable = !GameArg.GfxSkipHiresGFX;
|
||||||
#endif
|
#endif
|
||||||
auto full_screen_mode = HiresGFXAvailable ? initial_large_game_screen_mode : initial_small_game_screen_mode;
|
const auto full_screen_mode = HiresGFXAvailable
|
||||||
|
? screen_mode /* large_game_screen_mode */{640, 480}
|
||||||
|
: screen_mode /* small_game_screen_mode */{320, 200};
|
||||||
if (Game_screen_mode != full_screen_mode) {
|
if (Game_screen_mode != full_screen_mode) {
|
||||||
PlayerCfg.CockpitMode[1] = cockpit_mode_t::full_screen;
|
PlayerCfg.CockpitMode[1] = cockpit_mode_t::full_screen;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue