diff --git a/osu.Game.Rulesets.Osu/Objects/Slider.cs b/osu.Game.Rulesets.Osu/Objects/Slider.cs index d1c65fcce4..3bde7e790b 100644 --- a/osu.Game.Rulesets.Osu/Objects/Slider.cs +++ b/osu.Game.Rulesets.Osu/Objects/Slider.cs @@ -23,6 +23,7 @@ namespace osu.Game.Rulesets.Osu.Objects public double EndTime => StartTime + this.SpanCount() * Curve.Distance / Velocity; public double Duration => EndTime - StartTime; + public Vector2 StackedPositionAt(double t) => this.PositionAt(t) + StackOffset; public override Vector2 EndPosition => this.PositionAt(1); public SliderCurve Curve { get; } = new SliderCurve(); diff --git a/osu.Game.Rulesets.Osu/OsuDifficulty/OsuDifficultyCalculator.cs b/osu.Game.Rulesets.Osu/OsuDifficulty/OsuDifficultyCalculator.cs index 70cfbebfff..fb5acbb643 100644 --- a/osu.Game.Rulesets.Osu/OsuDifficulty/OsuDifficultyCalculator.cs +++ b/osu.Game.Rulesets.Osu/OsuDifficulty/OsuDifficultyCalculator.cs @@ -29,8 +29,7 @@ namespace osu.Game.Rulesets.Osu.OsuDifficulty protected override void PreprocessHitObjects() { - foreach (OsuHitObject h in Beatmap.HitObjects) - (h as Slider)?.Curve?.Calculate(); + new OsuBeatmapProcessor().PostProcess(Beatmap); } public override double Calculate(Dictionary categoryDifficulty = null) diff --git a/osu.Game.Rulesets.Osu/OsuDifficulty/Preprocessing/OsuDifficultyHitObject.cs b/osu.Game.Rulesets.Osu/OsuDifficulty/Preprocessing/OsuDifficultyHitObject.cs index 4f950353dc..c817cd0ff3 100644 --- a/osu.Game.Rulesets.Osu/OsuDifficulty/Preprocessing/OsuDifficultyHitObject.cs +++ b/osu.Game.Rulesets.Osu/OsuDifficulty/Preprocessing/OsuDifficultyHitObject.cs @@ -3,7 +3,6 @@ using System; using System.Linq; -using osu.Game.Rulesets.Objects.Types; using OpenTK; using osu.Game.Rulesets.Osu.Objects; @@ -95,7 +94,7 @@ namespace osu.Game.Rulesets.Osu.OsuDifficulty.Preprocessing var computeVertex = new Action(t => { // ReSharper disable once PossibleInvalidOperationException (bugged in current r# version) - var diff = slider.PositionAt(t) - slider.LazyEndPosition.Value; + var diff = slider.StackedPositionAt(t) - slider.LazyEndPosition.Value; float dist = diff.Length; if (dist > approxFollowCircleRadius)