Hiviexd / MVTaikoChecks

A set of osu!taiko Mapset Verifier checks
3 stars 2 forks source link

Add check for unsnapped last note hiding bar line #14

Closed hongaaronc closed 1 year ago

hongaaronc commented 1 year ago

Resolves #11

Summary

This adds a check to see if the last note is unsnapped 1ms early from its barline. This will result in that barline not being rendered.

For spinners and slider ends, this emits a minor warning. For hit circles, this emits a problem.

Implementation

Added some helper methods to TaikoUtils to find the offset from the nearest barline.

Emit an error if -2.0 < offset <= 1.0, since these seem to be the conditions where the issue based on my testing. In osu editor this basically appears as just -1ms due to rounding.

Testing

Tested using map from https://github.com/Hiviexd/MVTaikoChecks/issues/11#issuecomment-1741897398. Checked output of unsnapFromLastBarline to see what the offset looks like to the exact decimal, and see how the map responds to it.

hongaaronc commented 1 year ago

TaikoUtils.GetHeadOffsetFromNextBarlineMs() and TaikoUtils.GetTailOffsetFromNextBarlineMs() might be able to be written cleaner? Lmk if you have any ideas. The logic there is a bit confusing to follow but it definitely works.