Skip to content

Commit

Permalink
Merge pull request #29320 from peppy/autoamtic-download-default
Browse files Browse the repository at this point in the history
Change default for "automatically download beatmaps" to enabled
  • Loading branch information
smoogipoo authored Aug 7, 2024
2 parents b1488fd + 227878b commit e9a5b62
Showing 1 changed file with 1 addition and 16 deletions.
17 changes: 1 addition & 16 deletions osu.Game/Configuration/OsuConfigManager.cs
Original file line number Diff line number Diff line change
Expand Up @@ -67,13 +67,7 @@ protected override void InitialiseDefaults()
SetDefault(OsuSetting.Username, string.Empty);
SetDefault(OsuSetting.Token, string.Empty);

#pragma warning disable CS0618 // Type or member is obsolete
// this default set MUST remain despite the setting being deprecated, because `SetDefault()` calls are implicitly used to declare the type returned for the lookup.
// if this is removed, the setting will be interpreted as a string, and `Migrate()` will fail due to cast failure.
// can be removed 20240618
SetDefault(OsuSetting.AutomaticallyDownloadWhenSpectating, false);
#pragma warning restore CS0618 // Type or member is obsolete
SetDefault(OsuSetting.AutomaticallyDownloadMissingBeatmaps, false);
SetDefault(OsuSetting.AutomaticallyDownloadMissingBeatmaps, true);

SetDefault(OsuSetting.SavePassword, true).ValueChanged += enabled =>
{
Expand Down Expand Up @@ -244,12 +238,6 @@ public void Migrate()

// migrations can be added here using a condition like:
// if (combined < 20220103) { performMigration() }
if (combined < 20230918)
{
#pragma warning disable CS0618 // Type or member is obsolete
SetValue(OsuSetting.AutomaticallyDownloadMissingBeatmaps, Get<bool>(OsuSetting.AutomaticallyDownloadWhenSpectating)); // can be removed 20240618
#pragma warning restore CS0618 // Type or member is obsolete
}
}

public override TrackedSettings CreateTrackedSettings()
Expand Down Expand Up @@ -424,9 +412,6 @@ public enum OsuSetting
EditorAutoSeekOnPlacement,
DiscordRichPresence,

[Obsolete($"Use {nameof(AutomaticallyDownloadMissingBeatmaps)} instead.")] // can be removed 20240318
AutomaticallyDownloadWhenSpectating,

ShowOnlineExplicitContent,
LastProcessedMetadataId,
SafeAreaConsiderations,
Expand Down

0 comments on commit e9a5b62

Please sign in to comment.