mirror of
https://github.com/ppy/osu.git
synced 2024-12-14 07:33:20 +08:00
Fix nested logic not being completely correct (favouring already-passed rather than near-future)
This commit is contained in:
parent
79606317ab
commit
64b726d5ec
@ -107,7 +107,7 @@ namespace osu.Game.Rulesets.UI
|
||||
|
||||
// Else we want the earliest valid nested.
|
||||
// In cases of nested objects, they will always have earlier sample data than their parent object.
|
||||
return getAllNested(mostValidObject.HitObject).OrderBy(h => h.StartTime).FirstOrDefault(h => h.StartTime > getReferenceTime()) ?? mostValidObject.HitObject;
|
||||
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;
|
||||
|
Loading…
Reference in New Issue
Block a user