Move spectator begin/end playing to SubmittingPlayer

This commit is contained in:
Dan Balasescu
2022-07-28 20:44:02 +09:00
parent 1da9830145
commit ce694123eb
4 changed files with 37 additions and 52 deletions

View File

@ -14,7 +14,6 @@ using osu.Framework.Input.Events;
using osu.Game.Online.Spectator;
using osu.Game.Rulesets.Replays;
using osu.Game.Scoring;
using osu.Game.Screens.Play;
using osuTK;
namespace osu.Game.Rulesets.UI
@ -33,9 +32,6 @@ namespace osu.Game.Rulesets.UI
[Resolved]
private SpectatorClient spectatorClient { get; set; }
[Resolved]
private GameplayState gameplayState { get; set; }
protected ReplayRecorder(Score target)
{
this.target = target;
@ -48,15 +44,7 @@ namespace osu.Game.Rulesets.UI
protected override void LoadComplete()
{
base.LoadComplete();
inputManager = GetContainingInputManager();
spectatorClient.BeginPlaying(gameplayState, target);
}
protected override void Dispose(bool isDisposing)
{
base.Dispose(isDisposing);
spectatorClient?.EndPlaying(gameplayState);
}
protected override void Update()