mirror of
https://github.com/osukey/osukey.git
synced 2025-07-01 08:20:00 +09:00
Fix to work individually.
This commit is contained in:
@ -29,6 +29,7 @@ namespace osu.Game.Overlays
|
|||||||
private SpriteText title, artist;
|
private SpriteText title, artist;
|
||||||
|
|
||||||
private OsuGameBase osuGame;
|
private OsuGameBase osuGame;
|
||||||
|
private TrackManager trackManager;
|
||||||
private List<BeatmapSetInfo> playList;
|
private List<BeatmapSetInfo> playList;
|
||||||
private BeatmapDatabase database;
|
private BeatmapDatabase database;
|
||||||
private Bindable<WorkingBeatmap> beatmapSource;
|
private Bindable<WorkingBeatmap> beatmapSource;
|
||||||
@ -47,7 +48,8 @@ namespace osu.Game.Overlays
|
|||||||
beatmapSource = osuGame.Beatmap ?? new Bindable<WorkingBeatmap>();
|
beatmapSource = osuGame.Beatmap ?? new Bindable<WorkingBeatmap>();
|
||||||
current = beatmapSource.Value;
|
current = beatmapSource.Value;
|
||||||
if (database == null) database = osuGame.Beatmaps;
|
if (database == null) database = osuGame.Beatmaps;
|
||||||
playList = database.Query<BeatmapSetInfo>().ToList();
|
trackManager = osuGame.Audio.Track;
|
||||||
|
playList = database.GetAllWithChildren<BeatmapSetInfo>();
|
||||||
|
|
||||||
Width = 400;
|
Width = 400;
|
||||||
Height = 130;
|
Height = 130;
|
||||||
@ -229,6 +231,8 @@ namespace osu.Game.Overlays
|
|||||||
private void play(BeatmapInfo info, bool? isNext)
|
private void play(BeatmapInfo info, bool? isNext)
|
||||||
{
|
{
|
||||||
current = database.GetWorkingBeatmap(info, current);
|
current = database.GetWorkingBeatmap(info, current);
|
||||||
|
trackManager.SetExclusive(current.Track);
|
||||||
|
current.Track.Start();
|
||||||
beatmapSource.Value = current;
|
beatmapSource.Value = current;
|
||||||
updateCurrent(current, isNext);
|
updateCurrent(current, isNext);
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user