mirror of
https://github.com/ppy/osu.git
synced 2025-01-13 10:03:05 +08:00
Use IsLegacyRuleset extension method
This commit is contained in:
parent
1dae1149cb
commit
a7ac31fa34
@ -6,6 +6,7 @@
|
||||
using osu.Framework.Allocation;
|
||||
using osu.Framework.Graphics;
|
||||
using osu.Framework.Localisation;
|
||||
using osu.Game.Extensions;
|
||||
using osu.Game.Resources.Localisation.Web;
|
||||
using osu.Game.Rulesets;
|
||||
|
||||
@ -30,8 +31,7 @@ namespace osu.Game.Overlays.BeatmapListing
|
||||
foreach (var r in rulesets.AvailableRulesets)
|
||||
{
|
||||
// Don't display non-legacy rulesets
|
||||
int id = r.OnlineID;
|
||||
if (id < 0 || id > 3)
|
||||
if (!r.IsLegacyRuleset())
|
||||
continue;
|
||||
|
||||
AddItem(r);
|
||||
|
@ -6,6 +6,7 @@
|
||||
using osu.Framework.Graphics.UserInterface;
|
||||
using osu.Framework.Allocation;
|
||||
using osu.Framework.Logging;
|
||||
using osu.Game.Extensions;
|
||||
|
||||
namespace osu.Game.Rulesets
|
||||
{
|
||||
@ -28,9 +29,7 @@ namespace osu.Game.Rulesets
|
||||
{
|
||||
foreach (var ruleset in Rulesets.AvailableRulesets)
|
||||
{
|
||||
int id = ruleset.OnlineID;
|
||||
|
||||
if ((id < 0 || id > 3) && legacyOnly)
|
||||
if (!ruleset.IsLegacyRuleset() && legacyOnly)
|
||||
continue;
|
||||
|
||||
try
|
||||
|
Loading…
Reference in New Issue
Block a user