-
-
Notifications
You must be signed in to change notification settings - Fork 2.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Change osu!taiko's scrolling time range to match stable #26681
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Preliminary look
public const float DEFAULT_ASPECT = 16f / 9f; | ||
public const float MAXIMUM_ASPECT = 16f / 9f; | ||
public const float MINIMUM_ASPECT = 5f / 4f; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think it's better not to introduce terms like "DEFAULT" in public constants in the codebase, I would keep that constant in the helper method instead. Also probably best to make all these constants private, as they're no longer used anywhere outside of the class itself (see other comment).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Makes sense, applied in a46ca14, though do note that the maximum and minimum will need to be adjustable by mods in my next pr (to match stable's wider and mod-variable time range for classic mods)
float aspectRatio = Math.Clamp( | ||
DrawWidth / DrawHeight, | ||
TaikoPlayfieldAdjustmentContainer.MINIMUM_ASPECT, | ||
TaikoPlayfieldAdjustmentContainer.MAXIMUM_ASPECT); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I would move this inside the helper method, especially since part of the code relies on constants from that class in itself.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Applied in a46ca14. Because it needs access to the draw width and height, I've added a ComputeTimeRange
on TaikoPlayfieldAdjustmentContainer
too. DrawableTaikoEditorRuleset.ComputeTimeRange
seems a bit redundant now, but it's referenced in DrawableTaikoEditorRuleset
, so it's kept for now. Do let me know if it would be preferable to just use the one in adjustment container instead.
public const float MAXIMUM_ASPECT = 16f / 9f; | ||
public const float MINIMUM_ASPECT = 5f / 4f; | ||
|
||
public readonly IBindable<bool> LockPlayfieldAspectRange = new BindableBool(true); | ||
|
||
public static double AspectRatioToTimeRange(float aspectRatio) | ||
{ | ||
const float default_time_range = 7000 / TaikoBeatmapConverter.VELOCITY_MULTIPLIER; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It should be explicitly specified that such number was taken purely by visual comparison with stable. Also, can you give further insight as to why this number is being divided by VELOCITY_MULTIPLIER
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Comment added in a46ca14
It being divided by VELOCITY_MULTIPLIER
is to signify that it already takes into account the 1.4x speed up of taiko. To quote the current code's comment:
// Stable internally increased the slider velocity of objects by a factor of `VELOCITY_MULTIPLIER`.
// To simulate this, we shrink the time range by that factor here.
// This, when combined with the rest of the scrolling ruleset machinery (see `MultiplierControlPoint` et al.),
// has the effect of increasing each multiplier control point's multiplier by `VELOCITY_MULTIPLIER`, ensuring parity with stable.
Though now that it's a constant, we could just make the default 5000 instead. Or we could include this comment here. Do let me know if one of these would be preferable
const float default_time_range = 7000 / TaikoBeatmapConverter.VELOCITY_MULTIPLIER; | ||
|
||
// This is the fraction of the width that should not contribute to time range. | ||
const float ratio_compensator = 380f / 1366f; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Would name it non_playable_portion
at least.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Renamed in a46ca14
I've merged the other changes into this branch. Please make sure that things still look how you expect. By the way, I'm seeing a slight discrepancy, any idea about this? CleanShot.2024-01-26.at.10.00.06.mp4 |
Checked with #26616 but still has a discrepancy: CleanShot.2024-01-26.at.10.03.11.mp4 |
Can you test with default time range changed to I don't think I have access to an exact comparison method (unless the tool shown in the video is public, specifically the ability to synchronize between lazer/stable), but by comparing recordings
|
I just synchronised them using pause / cutting edge's rate adjustments (numbers 5-9) |
Ahh, thank you, it is much more precise than recording videos With that, I've found that the following values matches better:
It does nullify this particular point I've made in my original post though, I have no idea where 1/3 comes from. I think it's best to just specify that both of these are just taken visually by comparing with stable Comparisons:I've switched to the default skin for this, as the skin I was using before seems to not scale identically between the two clients 1280x7202024-01-28.13-59-24.mp41024x7682024-01-28.14-01-00.mp41280x10242024-01-28.14-02-40.mp4 |
I'll cross-compare this with stable code and see if I could nail it down to 1:1 match logically. |
@frenzibyte the hope is to get this in the next release (today). Are you going to get a chance to check this out? |
I will try my best to look into it today within hours from now. |
Closing in favour of #26781 |
This PR aims to address the time range difference of nomod between current lazer and stable (issue #25919). I'm also planning to base further changes for (classic) mods on this in a future PR, as this provides an easy way to convert between aspect ratio and time range matching stable's algorithm. I'm opening this as a separate PR as it seems to be easier to deal with this way.
To note:
default_time_range
is pretty much found by manually comparing with stable (which iirc was also the case for Change Taiko Classic NM, HD, HR and HDHR to better match stable #19604)ratio_compensator
is calculated from 200px (drum display) and 180px (input drum, taken from Define constant input drum width for osu!taiko #26632)DEFAULT_ASPECT
is only used byAspectRatioToTimeRange
so it could be moved into there. It's placed on the class for now since it seems to fit there next toMAXIMUM_ASPECT
andMINIMUM ASPECT
Comparisons
Note that because of display differences, note overlap and apparent velocity may be different. But time range (amount of notes shown on screen, or the time that a note appears from the right side) should be matching.
These issues should be alleviated by the other existing PRs aiming to match stable's display.
Apologies for the stuttery lazer recordings, I have no idea what's the cause (already using release build) but it doesn't seem to affect timings after notes start playing.
1920x1080 (16:9)
https://youtu.be/R7yaJFNhxQE
1280x1024 (5:4)
https://youtu.be/31CHiWGj1dE
1024x768 (4:3)
https://youtu.be/znIjYMx4Esk
Aspect ratio wider than 16:9
https://youtu.be/tSo2bz07JGY
Aspect ratio narrower than 5:4
https://youtu.be/WaaIMkHn66k