1
0
mirror of https://github.com/ppy/osu.git synced 2024-12-14 21:02:55 +08:00

Merge remote-tracking branch 'smoogipoo/timeshift-wip' into timeshift-wip

This commit is contained in:
Dean Herbert 2018-12-26 22:16:41 +09:00
commit f6aa6e6b3c
3 changed files with 6 additions and 2 deletions

View File

@ -66,7 +66,7 @@ namespace osu.Game.Online.Multiplayer
public void MapObjects(BeatmapManager beatmaps, RulesetStore rulesets)
{
// If we don't have an api beatmap, the request occurred as a result of room creation, so we can query the local beatmap instead
// Todo: Is this a bug?
// Todo: Is this a bug? Room creation only returns the beatmap ID
Beatmap = apiBeatmap == null ? beatmaps.QueryBeatmap(b => b.OnlineBeatmapID == BeatmapID) : apiBeatmap.ToBeatmap(rulesets);
Ruleset = rulesets.GetRuleset(RulesetID);

View File

@ -95,6 +95,8 @@ namespace osu.Game.Online.Multiplayer
// Todo: Temporary, should only remove/add new items (requires framework changes)
if (Playlist.Count == 0)
Playlist.AddRange(other.Playlist);
else if (other.Playlist.Count > 0)
Playlist.First().ID = other.Playlist.First().ID;
}
public bool ShouldSerializeRoomID() => false;

View File

@ -154,7 +154,9 @@ namespace osu.Game.Screens.Multi
{
foreach (var pi in remote.Playlist)
pi.MapObjects(beatmaps, rulesets);
local.CopyFrom(remote);
if (local != remote)
local.CopyFrom(remote);
}
/// <summary>