mirror of
https://github.com/ppy/osu.git
synced 2025-02-16 03:02:56 +08:00
fix null sample
This commit is contained in:
parent
a6e780a1b9
commit
83111223e0
@ -76,7 +76,8 @@ namespace osu.Game.Rulesets.Edit
|
|||||||
{
|
{
|
||||||
// Take the hitnormal sample of the last hit object
|
// Take the hitnormal sample of the last hit object
|
||||||
var lastHitNormal = beatmap.HitObjects.LastOrDefault(h => h.GetEndTime() < HitObject.StartTime)?.Samples?.FirstOrDefault(o => o.Name == HitSampleInfo.HIT_NORMAL);
|
var lastHitNormal = beatmap.HitObjects.LastOrDefault(h => h.GetEndTime() < HitObject.StartTime)?.Samples?.FirstOrDefault(o => o.Name == HitSampleInfo.HIT_NORMAL);
|
||||||
HitObject.Samples.Add(lastHitNormal);
|
if (lastHitNormal != null)
|
||||||
|
HitObject.Samples[0] = lastHitNormal;
|
||||||
|
|
||||||
placementHandler.BeginPlacement(HitObject);
|
placementHandler.BeginPlacement(HitObject);
|
||||||
if (commitStart)
|
if (commitStart)
|
||||||
|
Loading…
Reference in New Issue
Block a user