mirror of
https://github.com/ppy/osu.git
synced 2024-12-16 15:42:54 +08:00
Fix incorrect handling of nested objects when inside parent object's duration
This commit is contained in:
parent
126837fadd
commit
fdb47f8dfa
@ -74,12 +74,16 @@ namespace osu.Game.Screens.Edit.GameplayTest
|
||||
|
||||
static IEnumerable<HitObject> enumerateHitObjects(IEnumerable<HitObject> hitObjects, double cutoffTime)
|
||||
{
|
||||
foreach (var hitObject in hitObjects.Where(h => h.GetEndTime() < cutoffTime))
|
||||
foreach (var hitObject in hitObjects)
|
||||
{
|
||||
foreach (var nested in enumerateHitObjects(hitObject.NestedHitObjects, cutoffTime))
|
||||
yield return nested;
|
||||
{
|
||||
if (nested.GetEndTime() < cutoffTime)
|
||||
yield return nested;
|
||||
}
|
||||
|
||||
yield return hitObject;
|
||||
if (hitObject.GetEndTime() < cutoffTime)
|
||||
yield return hitObject;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user