mirror of
https://github.com/ppy/osu.git
synced 2025-02-22 03:52:54 +08:00
Reinstantiate mods for every player
This commit is contained in:
parent
1c952e58cc
commit
4c571acd67
@ -2,6 +2,7 @@
|
|||||||
// See the LICENCE file in the repository root for full licence text.
|
// See the LICENCE file in the repository root for full licence text.
|
||||||
|
|
||||||
using System;
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
using System.Linq;
|
using System.Linq;
|
||||||
using osu.Framework.Allocation;
|
using osu.Framework.Allocation;
|
||||||
using osu.Framework.Audio;
|
using osu.Framework.Audio;
|
||||||
@ -69,6 +70,10 @@ namespace osu.Game.Screens.Play
|
|||||||
|
|
||||||
protected GameplayClockContainer GameplayClockContainer { get; private set; }
|
protected GameplayClockContainer GameplayClockContainer { get; private set; }
|
||||||
|
|
||||||
|
[Cached]
|
||||||
|
[Cached(Type = typeof(IBindable<IEnumerable<Mod>>))]
|
||||||
|
protected readonly Bindable<IEnumerable<Mod>> SelectedMods = new Bindable<IEnumerable<Mod>>(Enumerable.Empty<Mod>());
|
||||||
|
|
||||||
private readonly bool allowPause;
|
private readonly bool allowPause;
|
||||||
private readonly bool showResults;
|
private readonly bool showResults;
|
||||||
|
|
||||||
@ -88,6 +93,8 @@ namespace osu.Game.Screens.Play
|
|||||||
{
|
{
|
||||||
this.api = api;
|
this.api = api;
|
||||||
|
|
||||||
|
SelectedMods.Value = base.SelectedMods.Value.Select(m => m.CreateCopy()).ToArray();
|
||||||
|
|
||||||
WorkingBeatmap working = loadBeatmap();
|
WorkingBeatmap working = loadBeatmap();
|
||||||
|
|
||||||
if (working == null)
|
if (working == null)
|
||||||
|
Loading…
Reference in New Issue
Block a user