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

Add basic density consideration to HP drain #26039

Merged
merged 2 commits into from
Dec 22, 2023

Conversation

smoogipoo
Copy link
Contributor

@smoogipoo smoogipoo commented Dec 22, 2023

Builds upon #26012 to add some basic form of density consideration.

I need more time to test this, but PRing for review for now.

The idea I'm going for is to normalise higher-density sections back to more reasonable values so that they don't skew the algorithm too much, while preserving some effects of density. Basically - taking the edge off.

In this implementation, a "section" refers to, at least for the osu! ruleset, a combo colour. This is completely theoretical at this point and I haven't tested the effect of applying the normalisation per-hitobject, but this may lead to more interesting effects around things like 1-combo bursts. Definitely needs more testing.

Replays.zip (compare vs PR above)

@peppy
Copy link
Member

peppy commented Dec 22, 2023

@smoogipoo if I was to do a build today, would you be interested in getting this out for testing? I guess let me know by the end of the day if so.

@smoogipoo
Copy link
Contributor Author

Yes, I would be interested in getting this out for testing.

@peppy peppy self-requested a review December 22, 2023 16:02
(int group, double avgIncrease)[] avgIncreasesByGroup = healthIncreases
.Where(i => i.Group != null)
.GroupBy(i => i.Group)
.Select(g => ((int)g.Key!, g.Sum(i => i.Amount) / (g.Max(i => i.Time) - g.Min(i => i.Time) + 1)))
Copy link
Member

Choose a reason for hiding this comment

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

this is definitely something of a line 🙈

@peppy peppy merged commit 21e9e10 into ppy:master Dec 22, 2023
14 of 16 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants