Convert to extension method to avoid recursive calls

This commit is contained in:
Dean Herbert
2022-03-03 14:15:25 +09:00
parent fab9323707
commit 42e07b7308
7 changed files with 13 additions and 14 deletions

View File

@ -72,6 +72,11 @@ namespace osu.Game.Extensions
return result;
}
/// <summary>
/// Check whether this <see cref="IRulesetInfo"/>'s online ID is within the range that defines it as a legacy ruleset (ie. either osu!, osu!taiko, osu!catch or osu!mania).
/// </summary>
public static bool IsLegacyRuleset(this IRulesetInfo ruleset) => ruleset.OnlineID >= 0 && ruleset.OnlineID <= ILegacyRuleset.MAX_LEGACY_RULESET_ID;
/// <summary>
/// Check whether the online ID of two <see cref="IBeatmapSetInfo"/>s match.
/// </summary>