ppy / osu

rhythm is just a *click* away!
https://osu.ppy.sh
MIT License
15.41k stars 2.29k forks source link

Testing catch beatmap cause extreme lag and causes misses #20221

Closed Vadeblade closed 6 months ago

Vadeblade commented 2 years ago

Type

Performance

Bug description

Testing seems to cause all objects to immediately me spawned at the catcher and causes extreme lag doing so

Screenshots or videos

https://user-images.githubusercontent.com/20312791/189481724-661b8a78-1fd8-4aff-a23b-7889c96e763b.mp4

Version

2022.902.1-lazer

Logs

network.log performance.log runtime.log updater.log database.log legacy-ipc.log

smoogipoo commented 2 years ago

I believe this is going to be an issue with every scrolling ruleset, and likely has to do with the initial lifetime.

peppy commented 2 years ago

Based on the video showing so many fruit being caught, might be a clock regression? Seems like it's potentially playing out more history than it should.

smoogipoo commented 2 years ago

Could be, but my doubts are high on that one. I think there was a similar issue with spectating in these rulesets. I'm not sure though, just listing my thoughts since I know scrolling rulesets do some stuff with the first update frame.

ekrctb commented 2 years ago

The cause of this issue is that LifetimeEnd is not set (default infinity) for rulesets. For standard, it is explicitly computed: https://github.com/ppy/osu/blob/9ac322d337e348f63d824e5995942c2ee367dc2a/osu.Game.Rulesets.Osu/UI/OsuPlayfield.cs#L217-L218

Currently, other rulesets relies on https://github.com/ppy/osu/blob/cbed268ac978ee1e6978fe645c47e6df73e6b99c/osu.Game/Rulesets/Objects/Drawables/DrawableHitObject.cs#L435-L436 for setting LifetimeEnd. But that is not available until a DHO is created, so it is impossible to "skip" hit objects at all. For scrolling scrolling, LifetimeEnd can be computed from an entry if we assume a hit object is just scrolling. But that is not always the case (like mania hold note head freezing) so I'm not sure about: whether automatic LifetimeEnd computation should be opt-out (overriden by rulesets) or opt-in (ruleset implementation always required).

(That LifetimeEnd logic of DrawableHitObject is confusing me so many times including https://github.com/ppy/osu/pull/20570#issuecomment-1269741388 so I want to it to be removed)

peppy commented 2 years ago

The case of the hold note head is a nested object, so a rule may be able to be established for top-level (non-nested) objects.

ekrctb commented 2 years ago

I found custom per-ruleset implementations are needed anyways because each ruleset has a different margin (hit objects must be alive there) after the end of a ScrollingHitObjectContainer.

peppy commented 2 years ago

In my work on the new mania skin, it definitely seems so (mania currently expires too early, haven't looked into why/where yet).

SecreOsu commented 6 months ago

Writing because post https://github.com/ppy/osu/issues/28150 got closed, but can this please be pushed through? 1.5 years of being a priority 1 issue with multiple people creating issues of this same problem. This completely makes the whole of the osu!catch editor unusable.

bdach commented 6 months ago

1.5 years of being a priority 1 issue with multiple people creating issues of this same problem.

there are over 100 p1 issues open.

This completely makes the whole of the osu!catch editor unusable.

and this is hyperbole. but your point is well taken.

peppy commented 6 months ago

Bumping to p0 due to report count.