1
0
mirror of https://github.com/ppy/osu.git synced 2026-05-13 20:33:35 +08:00

Make Ok adjustment formula more stable (#37263)

Current formula can output drastically different values on simlar
countOk / estimatedSliderBreaks amounts.
For example if countOk is 10, then changing estimatedSliderBreaks from 9
to 10 is gonna change okAdjustment from 0.15 to 0.05, what is a 3 times
lower resulting "estimated sliderbreaks" value.

This PR is fixing that in the most simple way - by increasing the buffer
constants, so very small variables won't skew the result as much.

---------

Co-authored-by: James Wilson <tsunyoku@gmail.com>
Co-authored-by: StanR <hi@stanr.info>
Co-authored-by: StanR <8269193+stanriders@users.noreply.github.com>
This commit is contained in:
Givy120
2026-05-06 15:31:20 +03:00
committed by GitHub
Unverified
parent 2b1d4aa245
commit d18edb54b0
@@ -397,7 +397,8 @@ namespace osu.Game.Rulesets.Osu.Difficulty
double estimatedSliderBreaks = Math.Min(nonMissMistakes, effectiveMissCount * topWeightedSliderFactor);
// Scores with more Oks and Mehs are more likely to have slider breaks.
double nonMissMistakeAdjustment = ((nonMissMistakes - estimatedSliderBreaks) + 0.5) / nonMissMistakes;
// We add an arbitrary value to both sides of the division to make it more stable on extreme ends.
double nonMissMistakeAdjustment = (nonMissMistakes - estimatedSliderBreaks + 4.5) / (nonMissMistakes + 4);
// There is a low probability of extra slider breaks on effective miss counts close to 1, as score based calculations are good at indicating if only a single break occurred.
estimatedSliderBreaks *= DifficultyCalculationUtils.Smoothstep(effectiveMissCount, 1, 2);