mirror of
https://github.com/ppy/osu
synced 2025-03-29 22:57:13 +00:00
Properly bind WaitingOnFrames
This commit is contained in:
parent
33cc5c5cb3
commit
b391a8f94e
@ -1,6 +1,7 @@
|
||||
// Copyright (c) ppy Pty Ltd <contact@ppy.sh>. Licensed under the MIT Licence.
|
||||
// See the LICENCE file in the repository root for full licence text.
|
||||
|
||||
using osu.Framework.Allocation;
|
||||
using osu.Framework.Bindables;
|
||||
using osu.Framework.Timing;
|
||||
using osu.Game.Beatmaps;
|
||||
@ -12,14 +13,20 @@ namespace osu.Game.Screens.OnlinePlay.Multiplayer.Spectate
|
||||
{
|
||||
public class MultiplayerSpectatorPlayer : SpectatorPlayer
|
||||
{
|
||||
private readonly SpectatorCatchUpSlaveClock gameplayClock;
|
||||
private readonly ISpectatorSlaveClock gameplayClock;
|
||||
|
||||
public MultiplayerSpectatorPlayer(Score score, SpectatorCatchUpSlaveClock gameplayClock)
|
||||
public MultiplayerSpectatorPlayer(Score score, ISpectatorSlaveClock gameplayClock)
|
||||
: base(score)
|
||||
{
|
||||
this.gameplayClock = gameplayClock;
|
||||
}
|
||||
|
||||
[BackgroundDependencyLoader]
|
||||
private void load()
|
||||
{
|
||||
gameplayClock.WaitingOnFrames.BindTo(DrawableRuleset.FrameStableClock.WaitingOnFrames);
|
||||
}
|
||||
|
||||
protected override GameplayClockContainer CreateGameplayClockContainer(WorkingBeatmap beatmap, double gameplayStart)
|
||||
=> new SubGameplayClockContainer(gameplayClock);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user