Use new helper method in `ModTimeRamp`

This commit is contained in:
Dean Herbert 2022-12-02 16:09:26 +09:00
parent a2db0afe19
commit 25120060aa
1 changed files with 1 additions and 2 deletions

View File

@ -7,7 +7,6 @@
using osu.Framework.Bindables;
using osu.Game.Beatmaps;
using osu.Game.Configuration;
using osu.Game.Rulesets.Objects;
using osu.Game.Rulesets.UI;
namespace osu.Game.Rulesets.Mods
@ -71,7 +70,7 @@ public virtual void ApplyToBeatmap(IBeatmap beatmap)
SpeedChange.SetDefault();
double firstObjectStart = beatmap.HitObjects.FirstOrDefault()?.StartTime ?? 0;
double lastObjectEnd = beatmap.HitObjects.LastOrDefault()?.GetEndTime() ?? 0;
double lastObjectEnd = beatmap.HitObjects.Any() ? beatmap.GetLastObjectTime() : 0;
beginRampTime = firstObjectStart;
finalRateTime = firstObjectStart + FINAL_RATE_PROGRESS * (lastObjectEnd - firstObjectStart);