From 5ef67250b56294ba229492d634c86cf2df1ed2aa Mon Sep 17 00:00:00 2001 From: Derrick Timmermans Date: Fri, 26 Jan 2024 09:11:26 +0100 Subject: [PATCH] Use Samples instead of NodeSamples in Slides NodeSamples no longer has a purpose now that SlideBodies don't play samples anymore --- .../Beatmaps/Converter/SentakkiBeatmapConverter.Slider.cs | 2 +- .../Beatmaps/SentakkiBeatmapConverterOld.cs | 2 +- osu.Game.Rulesets.Sentakki/Objects/Drawables/DrawableSlide.cs | 4 ++++ osu.Game.Rulesets.Sentakki/Objects/Slide.cs | 4 +--- 4 files changed, 7 insertions(+), 5 deletions(-) diff --git a/osu.Game.Rulesets.Sentakki/Beatmaps/Converter/SentakkiBeatmapConverter.Slider.cs b/osu.Game.Rulesets.Sentakki/Beatmaps/Converter/SentakkiBeatmapConverter.Slider.cs index ed27c5e88..ea945faff 100644 --- a/osu.Game.Rulesets.Sentakki/Beatmaps/Converter/SentakkiBeatmapConverter.Slider.cs +++ b/osu.Game.Rulesets.Sentakki/Beatmaps/Converter/SentakkiBeatmapConverter.Slider.cs @@ -73,7 +73,7 @@ private SentakkiHitObject convertSlider(HitObject original) }, Lane = lane.NormalizePath(), StartTime = original.StartTime, - NodeSamples = nodeSamples, + Samples = nodeSamples.FirstOrDefault(), Break = headBreak }; diff --git a/osu.Game.Rulesets.Sentakki/Beatmaps/SentakkiBeatmapConverterOld.cs b/osu.Game.Rulesets.Sentakki/Beatmaps/SentakkiBeatmapConverterOld.cs index 22427c89b..7cec144cc 100644 --- a/osu.Game.Rulesets.Sentakki/Beatmaps/SentakkiBeatmapConverterOld.cs +++ b/osu.Game.Rulesets.Sentakki/Beatmaps/SentakkiBeatmapConverterOld.cs @@ -310,7 +310,7 @@ private SentakkiHitObject createTouchNote(HitObject original) }, Lane = noteLane, StartTime = original.StartTime, - NodeSamples = samples, + Samples = samples.FirstOrDefault(), Break = hasBreakHead }; } diff --git a/osu.Game.Rulesets.Sentakki/Objects/Drawables/DrawableSlide.cs b/osu.Game.Rulesets.Sentakki/Objects/Drawables/DrawableSlide.cs index 32dffa16d..a0fadbafb 100644 --- a/osu.Game.Rulesets.Sentakki/Objects/Drawables/DrawableSlide.cs +++ b/osu.Game.Rulesets.Sentakki/Objects/Drawables/DrawableSlide.cs @@ -44,6 +44,10 @@ private void load() } }); } + protected override void LoadSamples() + { + // The slide parent object doesn't need a sample + } protected override void CheckForResult(bool userTriggered, double timeOffset) { diff --git a/osu.Game.Rulesets.Sentakki/Objects/Slide.cs b/osu.Game.Rulesets.Sentakki/Objects/Slide.cs index c8479a232..00ad08906 100644 --- a/osu.Game.Rulesets.Sentakki/Objects/Slide.cs +++ b/osu.Game.Rulesets.Sentakki/Objects/Slide.cs @@ -27,8 +27,6 @@ public double Duration set => throw new NotSupportedException(); } - public IList> NodeSamples = new List>(); - public double EndTime => StartTime + Duration; public override Color4 DefaultNoteColour => Color4.Aqua; @@ -45,7 +43,7 @@ protected override void CreateNestedHitObjects(CancellationToken cancellationTok { LaneBindable = { BindTarget = LaneBindable }, StartTime = StartTime, - Samples = NodeSamples.Any() ? NodeSamples.First() : new List(), + Samples = Samples, Break = Break, Ex = Ex });