X-Git-Url: https://git.artsoft.org/?a=blobdiff_plain;f=src%2Flibgame%2Fsystem.c;h=00e9c7295edde77c0f1f3fd117c39a29bb69c72a;hb=89401883eeb279c7101b1c635477a9bccc123d21;hp=98ccd70cafb02341a04ba4f367c82bf0d5251621;hpb=bf9e47bb97f16c998644758a383209fa4d4fc87b;p=rocksndiamonds.git diff --git a/src/libgame/system.c b/src/libgame/system.c index 98ccd70c..00e9c729 100644 --- a/src/libgame/system.c +++ b/src/libgame/system.c @@ -33,6 +33,7 @@ struct OptionInfo options; struct VideoSystemInfo video; struct AudioSystemInfo audio; struct GfxInfo gfx; +struct OverlayInfo overlay; struct ArtworkInfo artwork; struct JoystickInfo joystick; struct SetupInfo setup; @@ -97,6 +98,16 @@ void InitProgramInfo(char *argv0, char *config_filename, char *userdata_subdir, program.log_file[LOG_ERR_ID] = program.log_file_default[LOG_ERR_ID] = stderr; } +void InitScoresInfo() +{ + char *global_scores_dir = getPath2(getCommonDataDir(), SCORES_DIRECTORY); + + program.global_scores = directoryExists(global_scores_dir); + program.many_scores_per_name = !program.global_scores; + + free(global_scores_dir); +} + void SetWindowTitle() { program.window_title = program.window_title_function(); @@ -270,6 +281,21 @@ void InitGfxOtherSettings() gfx.cursor_mode = CURSOR_DEFAULT; } +void InitOverlayInfo() +{ + overlay.active = FALSE; +} + +void SetOverlayActive(boolean active) +{ + overlay.active = active; +} + +boolean GetOverlayActive() +{ + return overlay.active; +} + void SetDrawDeactivationMask(int draw_deactivation_mask) { gfx.draw_deactivation_mask = draw_deactivation_mask; @@ -363,7 +389,9 @@ void LimitScreenUpdates(boolean enable) void InitVideoDisplay(void) { SDLInitVideoDisplay(); +#if defined(TARGET_SDL2) SDLSetDisplaySize(); +#endif } void CloseVideoDisplay(void)