From: Holger Schemel Date: Sun, 13 Dec 2020 20:10:05 +0000 (+0100) Subject: added setup values for tile selection cursor for MM game engine X-Git-Tag: 4.2.1.0~58 X-Git-Url: https://git.artsoft.org/?a=commitdiff_plain;h=22d6bccc33b6a7ddd0961be470d72800f171579c;p=rocksndiamonds.git added setup values for tile selection cursor for MM game engine --- diff --git a/src/files.c b/src/files.c index 0de6f338..12813f59 100644 --- a/src/files.c +++ b/src/files.c @@ -9153,6 +9153,14 @@ static struct TokenInfo debug_setup_tokens[] = TYPE_BOOLEAN, &setup.debug.show_frames_per_second, "debug.show_frames_per_second" }, + { + TYPE_SWITCH3, + &setup.debug.xsn_mode, "debug.xsn_mode" + }, + { + TYPE_INTEGER, + &setup.debug.xsn_percent, "debug.xsn_percent" + }, }; static struct TokenInfo options_setup_tokens[] = @@ -9426,11 +9434,16 @@ static void setSetupInfoToDefaults(struct SetupInfo *si) si->debug.show_frames_per_second = FALSE; + si->debug.xsn_mode = AUTO; + si->debug.xsn_percent = 0; + si->options.verbose = FALSE; #if defined(PLATFORM_ANDROID) si->fullscreen = TRUE; #endif + + setHideSetupEntry(&setup.debug.xsn_mode); } static void setSetupInfoToDefaults_AutoSetup(struct SetupInfo *si) @@ -9871,7 +9884,9 @@ void SaveSetup(void) fprintf(file, "\n"); for (i = 0; i < ARRAY_SIZE(debug_setup_tokens); i++) - fprintf(file, "%s\n", getSetupLine(debug_setup_tokens, "", i)); + if (!strPrefix(debug_setup_tokens[i].text, "debug.xsn_") || + setup.debug.xsn_mode != AUTO) + fprintf(file, "%s\n", getSetupLine(debug_setup_tokens, "", i)); fprintf(file, "\n"); for (i = 0; i < ARRAY_SIZE(options_setup_tokens); i++) diff --git a/src/libgame/system.h b/src/libgame/system.h index 30772b4b..c1eb58d8 100644 --- a/src/libgame/system.h +++ b/src/libgame/system.h @@ -1368,6 +1368,8 @@ struct SetupDebugInfo boolean frame_delay_use_mod_key; boolean frame_delay_game_only; boolean show_frames_per_second; + int xsn_mode; + int xsn_percent; }; struct SetupInfo