mirror of
https://github.com/ppy/osu.git
synced 2024-11-11 10:33:30 +08:00
fixed sample control point applying
This commit is contained in:
parent
5accb05f45
commit
1b4f4372d5
@ -118,10 +118,7 @@ namespace osu.Game.Beatmaps.Formats
|
||||
|
||||
SampleControlPoint sampleControlPoint = legacyInfo != null ? legacyInfo.SamplePointAt(hitObject.GetEndTime() + control_point_leniency) : SampleControlPoint.DEFAULT;
|
||||
|
||||
foreach (var hitSampleInfo in hitObject.Samples)
|
||||
{
|
||||
sampleControlPoint.ApplyTo(hitSampleInfo);
|
||||
}
|
||||
hitObject.Samples = hitObject.Samples.Select(o => sampleControlPoint.ApplyTo(o)).ToList();
|
||||
|
||||
if (hitObject is not IHasRepeats hasRepeats) return;
|
||||
|
||||
@ -130,10 +127,7 @@ namespace osu.Game.Beatmaps.Formats
|
||||
double time = hitObject.StartTime + i * hasRepeats.Duration / hasRepeats.SpanCount() + control_point_leniency;
|
||||
sampleControlPoint = legacyInfo != null ? legacyInfo.SamplePointAt(time) : SampleControlPoint.DEFAULT;
|
||||
|
||||
foreach (var hitSampleInfo in hasRepeats.NodeSamples[i])
|
||||
{
|
||||
sampleControlPoint.ApplyTo(hitSampleInfo);
|
||||
}
|
||||
hasRepeats.NodeSamples[i] = hasRepeats.NodeSamples[i].Select(o => sampleControlPoint.ApplyTo(o)).ToList();
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user