mirror of
https://github.com/ppy/osu.git
synced 2024-11-11 12:17:26 +08:00
Checker -> BeatmapVerifier
This commit is contained in:
parent
14bd5bdc77
commit
1c553b5d48
@ -10,7 +10,7 @@ using osu.Game.Rulesets.Osu.Edit.Checks;
|
||||
|
||||
namespace osu.Game.Rulesets.Osu.Edit
|
||||
{
|
||||
public class OsuChecker : Checker
|
||||
public class OsuBeatmapVerifier : BeatmapVerifier
|
||||
{
|
||||
private readonly List<Check> checks = new List<Check>
|
||||
{
|
@ -206,7 +206,7 @@ namespace osu.Game.Rulesets.Osu
|
||||
|
||||
public override HitObjectComposer CreateHitObjectComposer() => new OsuHitObjectComposer(this);
|
||||
|
||||
public override Checker CreateChecker() => new OsuChecker();
|
||||
public override BeatmapVerifier CreateChecker() => new OsuBeatmapVerifier();
|
||||
|
||||
public override string Description => "osu!";
|
||||
|
||||
|
@ -9,7 +9,7 @@ using osu.Game.Rulesets.Edit.Checks.Components;
|
||||
|
||||
namespace osu.Game.Rulesets.Edit
|
||||
{
|
||||
public abstract class Checker
|
||||
public abstract class BeatmapVerifier
|
||||
{
|
||||
// These are all ruleset-invariant, hence here instead of in e.g. `OsuChecker`.
|
||||
private readonly IReadOnlyList<Check> checks = new List<Check>
|
@ -202,7 +202,7 @@ namespace osu.Game.Rulesets
|
||||
|
||||
public virtual HitObjectComposer CreateHitObjectComposer() => null;
|
||||
|
||||
public virtual Checker CreateChecker() => null;
|
||||
public virtual BeatmapVerifier CreateChecker() => null;
|
||||
|
||||
public virtual Drawable CreateIcon() => new SpriteIcon { Icon = FontAwesome.Solid.QuestionCircle };
|
||||
|
||||
|
@ -21,7 +21,7 @@ namespace osu.Game.Screens.Edit.Verify
|
||||
public class VerifyScreen : EditorScreen
|
||||
{
|
||||
private Ruleset ruleset;
|
||||
private static Checker checker;
|
||||
private static BeatmapVerifier beatmapVerifier;
|
||||
|
||||
[Cached]
|
||||
private Bindable<Issue> selectedIssue = new Bindable<Issue>();
|
||||
@ -36,7 +36,7 @@ namespace osu.Game.Screens.Edit.Verify
|
||||
var dependencies = new DependencyContainer(base.CreateChildDependencies(parent));
|
||||
|
||||
ruleset = parent.Get<IBindable<WorkingBeatmap>>().Value.BeatmapInfo.Ruleset?.CreateInstance();
|
||||
checker = ruleset?.CreateChecker();
|
||||
beatmapVerifier = ruleset?.CreateChecker();
|
||||
|
||||
return dependencies;
|
||||
}
|
||||
@ -128,9 +128,9 @@ namespace osu.Game.Screens.Edit.Verify
|
||||
|
||||
private void refresh()
|
||||
{
|
||||
table.Issues = checker.Run(Beatmap)
|
||||
.OrderByDescending(issue => issue.Template.Type)
|
||||
.ThenByDescending(issue => issue.Template.Origin.Metadata().Category);
|
||||
table.Issues = beatmapVerifier.Run(Beatmap)
|
||||
.OrderByDescending(issue => issue.Template.Type)
|
||||
.ThenByDescending(issue => issue.Template.Origin.Metadata().Category);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user