1
0
mirror of https://github.com/ppy/osu.git synced 2025-02-15 15:23:14 +08:00

Consume nested object states in HitObjectLifetimeEntry

This commit is contained in:
Dean Herbert 2023-07-03 13:29:44 +09:00
parent 759cd5aec7
commit 561fff801a

View File

@ -126,7 +126,7 @@ namespace osu.Game.Rulesets.UI
return getAllNested(mostValidObject.HitObject).OrderBy(h => h.GetEndTime()).SkipWhile(h => h.GetEndTime() <= getReferenceTime()).FirstOrDefault() ?? mostValidObject.HitObject;
}
private bool isAlreadyHit(HitObjectLifetimeEntry h) => h.Result?.HasResult == true;
private bool isAlreadyHit(HitObjectLifetimeEntry h) => h.AllJudged;
private bool isCloseEnoughToCurrentTime(HitObject h) => getReferenceTime() >= h.StartTime - h.HitWindows.WindowFor(HitResult.Miss) * 2;
private double getReferenceTime() => gameplayClock?.CurrentTime ?? Clock.CurrentTime;