1
0
mirror of https://github.com/ppy/osu.git synced 2025-01-28 07:23:14 +08:00

Inline method

This commit is contained in:
smoogipoo 2018-05-14 17:45:11 +09:00
parent 6eb7590ab0
commit 4ceae6ba1f

View File

@ -306,7 +306,10 @@ namespace osu.Game.Overlays
var playable = beatmapSets.TakeWhile(i => i.ID != current.BeatmapSetInfo.ID).LastOrDefault() ?? beatmapSets.LastOrDefault();
if (playable != null)
playSpecified(playable.Beatmaps.First());
{
beatmapBacking.Value = beatmaps.GetWorkingBeatmap(playable.Beatmaps.First(), beatmapBacking);
beatmapBacking.Value.Track.Restart();
}
}
private void next(bool instant = false)
@ -315,13 +318,10 @@ namespace osu.Game.Overlays
var playable = beatmapSets.SkipWhile(i => i.ID != current.BeatmapSetInfo.ID).Skip(1).FirstOrDefault() ?? beatmapSets.FirstOrDefault();
if (playable != null)
playSpecified(playable.Beatmaps.First());
}
private void playSpecified(BeatmapInfo info)
{
beatmapBacking.Value = beatmaps.GetWorkingBeatmap(info, beatmapBacking);
beatmapBacking.Value.Track.Restart();
{
beatmapBacking.Value = beatmaps.GetWorkingBeatmap(playable.Beatmaps.First(), beatmapBacking);
beatmapBacking.Value.Track.Restart();
}
}
private WorkingBeatmap current;