Simplify/improve beatmap conversion precheck

This commit is contained in:
smoogipoo
2019-12-23 17:44:18 +09:00
parent cc808a9eb1
commit 6e7426a098
9 changed files with 13 additions and 18 deletions

View File

@ -4,7 +4,7 @@
using osu.Game.Beatmaps;
using osu.Game.Rulesets.Catch.Objects;
using System.Collections.Generic;
using System;
using System.Linq;
using osu.Game.Rulesets.Catch.UI;
using osu.Game.Rulesets.Objects.Types;
using osu.Game.Rulesets.Objects;
@ -19,7 +19,7 @@ namespace osu.Game.Rulesets.Catch.Beatmaps
{
}
protected override IEnumerable<Type> ValidConversionTypes { get; } = new[] { typeof(IHasXPosition) };
public override bool CanConvert() => Beatmap.HitObjects.All(h => h is IHasXPosition);
protected override IEnumerable<CatchHitObject> ConvertHitObject(HitObject obj, IBeatmap beatmap)
{