Skip to content
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

Include sliders in accuracy pp if slider head accuracy is in use #27063

Merged
merged 10 commits into from
Oct 7, 2024
2 changes: 2 additions & 0 deletions osu.Game.Rulesets.Osu/Difficulty/OsuPerformanceCalculator.cs
Original file line number Diff line number Diff line change
Expand Up @@ -192,6 +192,8 @@ private double computeAccuracyValue(ScoreInfo score, OsuDifficultyAttributes att
// This percentage only considers HitCircles of any value - in this part of the calculation we focus on hitting the timing hit window.
double betterAccuracyPercentage;
int amountHitObjectsWithAccuracy = attributes.HitCircleCount;
if (!score.Mods.Any(h => h is OsuModClassic cl && cl.NoSliderHeadAccuracy.Value))
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The change itself is fine, but I'll raise the same point I keep bringing in all other lazer-related pp PRs - I strongly believe we need to split calculators into classic and non-classic because of the code bloat (lots of possible if lazer or classic all around the calc) and more complete score data on new scores that we can (I hope?) utilise.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

all the difference lazer have is new information, so it's not a lot of code bloat, around 10-15 additional lines to covers this i think
also, this thing is not a lazer vs stable, it's CL vs non CL

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

All stable scores are CL by default and all lazer scores are non-CL by default. Treating lazer CL differently compared to stable auto-CL doesn't make much sense therefore CL scores must always use stable score data structure.

Mod ifs are already a big mess in pp calc now, adding CL handling on top would make it even more convoluted. Keep in mind that we have to handle both extended score data and legacy score data since stable is here to stay

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I agree that it might get a little messy to sprinkle CL checks everywhere, however I equally see it being messy having to maintain 2 separate calculators that will share (mostly) the same logic. Having to make identical changes in 2 places whenever PP changes doesn't sound like a particularly great alternative.

amountHitObjectsWithAccuracy += attributes.SliderCount;

if (amountHitObjectsWithAccuracy > 0)
betterAccuracyPercentage = ((countGreat - (totalHits - amountHitObjectsWithAccuracy)) * 6 + countOk * 2 + countMeh) / (double)(amountHitObjectsWithAccuracy * 6);
Expand Down
Loading