Open DeviousPanda opened 3 years ago
I think that there is an interesting avenue to explore here, in integrating https://github.com/Naxesss/MapsetVerifier with lazer directly. The good news is that its processing components are C# already, but the bad news is that it's coupled to a custom beatmap parser. And well, we probably ought to ask for permission first.
The repository license for all C# components are MIT (Expat), so I think that with proper crediting, asking for permission is not necessary.
I'd be interested in helping out with integrating Mapset Verifier into lazer.
Design-wise the main interest is probably the Check
class and its subclasses BeatmapCheck
, BeatmapsetCheck
, and GeneralCheck
.
Check | Argument | Notes | Usage |
---|---|---|---|
BeatmapCheck |
Beatmap |
Run for each Beatmap . |
Checks isolated to a single beatmap (e.g. unsnapped objects). |
BeatmapsetCheck |
Beatmapset |
Run for each Beatmap . |
Checks on each beatmap + requiring context of the set (e.g. checking for inconsistencies with other beatmaps in the set). |
GeneralCheck |
Beatmapset |
Run once per Beatmapset . |
Checks on the set as a whole (e.g. checking the files in the song folder). |
This way, BeatmapCheck
s can be run concurrently on each Beatmap
, where each Beatmap
in a Beatmapset
can be processed as such concurrently as well, along-side BeatmapsetCheck
s and GeneralCheck
s. All checks return IEnumerable<Issue>
, where the templates of the Issue
s are decided by the respective Check
.
For a simple example, the CheckPreview
class (extending BeatmapsetCheck
) has two types of issues it can give:
IssueTemplate | IssueType | Description | Arguments |
---|---|---|---|
Not set | Problem | Preview time is not set. | N/A |
Inconsistent | Problem | Preview time is inconsistent, see {difficulty}. | difficulty |
Here's how it's displayed in the application if both issues are present:
I figure we could do something similar for lazer. Possibly as a tab like compose, timing, etc.
Allowing users to create custom checks would be really useful considering that the RC changes quite often, so this is something we may want to consider designing around.
A good starting point may be to add a new tab in the editor alongside the existing ones, and show issues in a similar tabulated format to how timing is done. Improving the design and UX could come as a secondary pass.
I'd probably push back against custom rules, as I'd hope the ones in the game would be kept up-to-date and flexible enough to a point this would not be required.
Note that currently we only load the active difficulty. You could quite easily parse the others, but I'd start with just focusing on the current one to begin with for simplicity.
As an aside, the osu-stable code base for AiMod is relatively portable, and written with extensibility in mind. If someone is looking to take this task on and would like that code as a reference, let me know and I'll extract it out.
The majority of this has now been implemented, but will keep this issue open to track completion of all required checks to bring this up to parity.
Now that we've added a few checks I'm going to list and organize them so it's easier figure out what to work on next, as well as to highlight what is currently blocked and what I'm uncertain of. I'll be updating this as I go.
Here are all checks from Mapset Verifier and their respective status in lazer. These are sorted by priority (0 = very common and/or severe) and then by difficulty of implementation. This includes most if not all relevant checks from AiMod.
βοΈ Done π‘ Done, but not merged β Not looked at yet βοΈ Unnecessary π Blocked
Check | Status | Difficulty | Priority |
---|---|---|---|
Missing background. | βοΈ https://github.com/ppy/osu/pull/12361 | β | 0 |
Multiple or missing audio files. | βοΈ https://github.com/ppy/osu/pull/12492 π Can't check multipleΒΉ. | β | 0 |
Inconsistent or unset preview time. | π Can't check inconsistentΒΉ. π‘ Β² | β | 0 |
Inconsistent metadata. | π ΒΉ π‘ Β² | β | 0 |
Inconsistent uninherited lines, meter signatures or BPM. | π ΒΉ | β | 0 |
Too high or low audio bitrate. | βοΈ https://github.com/ppy/osu/pull/12492 | β β | 0 |
Unsnapped hitobjects. | βοΈ https://github.com/ppy/osu/pull/12588 | β β | 0 |
Concurrent hitobjects. | βοΈ https://github.com/ppy/osu/pull/12588 | β β | 0 |
Inconsistent mapset id, countdown, epilepsy warning, etc. | π ΒΉ π‘ Β² | β β | 0 |
Low volume hitsounding. | βοΈ https://github.com/ppy/osu/pull/13669 | β | 1 |
Too short hitsounds. | βοΈ https://github.com/ppy/osu/pull/13871 | β | 1 |
0-byte files. | βοΈ https://github.com/ppy/osu/pull/13871 | β | 1 |
Inconsistent video usage. | π ΒΉ | β | 1 |
Objects too close together. | β (< 10 ms) | β | 1 |
Too high or low background resolution. | βοΈ https://github.com/ppy/osu/pull/12492 | β β | 1 |
Lowest difficulty too difficult for the given drain/play time(s). | π ΒΉ | β β | 1 |
Audio channels in video. | βοΈ https://github.com/ppy/osu/pull/13871 | β β | 1 |
Delayed hitsounds. | β | β β β | 1 |
Wrongly or inconsistently snapped hitobjects. | π ΒΉ | β β β | 1 |
Too high video resolution. | β | β | 2 |
Missing genre/language in tags. | π‘ Not PRed yet | β | 2 |
Unicode in romanized fields. | π‘ Not PRed, will batch together with other metadata checks. | β | 2 |
Abnormal difficulty settings. | β | β | 2 |
Too short drain time. | β | β | 2 |
Zero-length objects. | βοΈ https://github.com/ppy/osu/pull/13874 | β | 2 |
Too high sprite resolution. | β | β β | 2 |
Incorrect marker format. | β | β β | 2 |
Incorrect marker spacing. | β | β β | 2 |
Incorrect format of (TV Size) / (Game Ver.) / (Short Ver.) / (Sped Up Ver.) in title. | β | β β | 2 |
More than 20% unused audio at the end. | β | β β | 2 |
Incorrect hitsound format. | β | β β | 2 |
Slider tick rates not aligning with any common beat snap divisor. | β | β β | 2 |
Unused timing lines. | β Possibly unnecessary. Made to prevent shifts in timing due to uninherited lines rounding their time to an integer, even when the cursor is at a decimal time (e.g. snapped to prior timing). May work differently in lazer. | β β | 2 |
Overlay layer usage. | β | β | 3 |
Inconsistent video offset. | π ΒΉ | β | 3 |
Unsnapped kiai. | β | β | 3 |
Abnormal amount of slider nodes. | β | β | 3 |
First line toggles kiai or is inherited. | β Possibly unnecessary. Nothing to inherit, causing undefined behaviour. Kiai causes the entire intro prior to the line to act as if in kiai. May work differently in lazer. | β | 3 |
Incorrect audio format. | β | β β | 3 |
Imbalanced hitsounds. | β | β β | 3 |
Breaks only achievable through .osu editing. | β Possibly unnecessary. Can throw off break timing in a way where gameplay happens while the break visuals are still going. Not visible in the editor, making it easy to miss. May work differently in lazer. | β β | 3 |
Frequent finish hitsounds. | β | β β β | 3 |
Concurrent or conflicting timing lines. | βοΈNo longer be possible with the new control point system. It is possible to add another point 0.000001 ms earlier/later, but doesn't seem worth implementing a check for. | - | - |
Unused files. | βοΈ Unused files are automatically removed. | - | - |
Issues with updating or downloading. | βοΈ Made to prevent bugs specifically in stable and its interaction with BSS. Could feasibly be made into upload restrictions in lazer if anything is still an issue. | - | - |
Check | Status | Difficulty | Priority |
---|---|---|---|
Long periods without hitsounding. | βοΈ https://github.com/ppy/osu/pull/13669 + checks other rulesets as well (TODO: probably need to exclude taiko, though). | β β | 0 |
Offscreen hitobjects. | βοΈ https://github.com/ppy/osu/pull/12361 | β β | 0 |
Hitobject is unaffected by a line very close to it. | β | β β | 0 |
Object too close or far away from previous. | βοΈ https://github.com/ppy/osu/pull/13606 | β β β | 0 |
Multiple reverses on too short sliders. | β | β | 1 |
Too short sliders. | βοΈ https://github.com/ppy/osu/pull/13874 | β | 1 |
Too short spinner. | βοΈ https://github.com/ppy/osu/pull/13874 | β | 1 |
Objects close in time not overlapping. | βοΈ https://github.com/ppy/osu/pull/13606 + checks when it should overlap too. | β β | 1 |
Too short spinner time or spinner recovery time. | β | β β | 1 |
Perfect stacks too close in time. | β | β | 2 |
Too dark or bright combo colours or slider borders. | β | β β | 2 |
Perfectly overlapping combination of tail, head or red anchors. | β | β β | 2 |
Obscured reverse arrows. | β | β β | 2 |
Burai slider. | β | β β β | 2 |
Default combo colours without forced skin. | β | β | 3 |
Storyboarded hitsounds. | β | β β | 3 |
ΒΉ - Editor lacks context of other difficulties, so any check that compares difficulties cannot be implemented. Β² - Not PRed. Didn't realize it wouldn't work in-game, but will keep checks & tests around for whenever this gets unblocked.
Right now lazer has no internal way to check for errors that can be undetectable or almost impossible to find within a beatmap
while a good solution would be to add AiMod into lazer, the actual release of lazer gives a great opportunity to upgrading the old AiMod to be up to date with the current modding standards
it's probably worth having a discussion on what (if any) modding support you want to add to lazer (and im also sure that alot of the bng/nat groups would like to give input on different features a modding assistant could have) but i see huge potential with a up to date AiMod within the game, which could also act like an auto ranking criteria checker
(split from https://github.com/ppy/osu/issues/12020)