diff --git a/osu.Game/Screens/OnlinePlay/Multiplayer/Spectate/MultiSpectatorScreen.cs b/osu.Game/Screens/OnlinePlay/Multiplayer/Spectate/MultiSpectatorScreen.cs
index c45e3a79da..7bf8ce0e1a 100644
--- a/osu.Game/Screens/OnlinePlay/Multiplayer/Spectate/MultiSpectatorScreen.cs
+++ b/osu.Game/Screens/OnlinePlay/Multiplayer/Spectate/MultiSpectatorScreen.cs
@@ -213,8 +213,8 @@ namespace osu.Game.Screens.OnlinePlay.Multiplayer.Spectate
{
}
- protected override void StartGameplay(int userId, GameplayState gameplayState)
- => instances.Single(i => i.UserId == userId).LoadScore(gameplayState.Score);
+ protected override void StartGameplay(int userId, SpectatorGameplayState spectatorGameplayState)
+ => instances.Single(i => i.UserId == userId).LoadScore(spectatorGameplayState.Score);
protected override void EndGameplay(int userId)
{
diff --git a/osu.Game/Screens/Play/SoloSpectator.cs b/osu.Game/Screens/Play/SoloSpectator.cs
index 4520e2e825..9d4dad8bdc 100644
--- a/osu.Game/Screens/Play/SoloSpectator.cs
+++ b/osu.Game/Screens/Play/SoloSpectator.cs
@@ -56,7 +56,7 @@ namespace osu.Game.Screens.Play
/// The player's immediate online gameplay state.
/// This doesn't always reflect the gameplay state being watched.
///
- private GameplayState immediateGameplayState;
+ private SpectatorGameplayState immediateSpectatorGameplayState;
private GetBeatmapSetRequest onlineBeatmapRequest;
@@ -146,7 +146,7 @@ namespace osu.Game.Screens.Play
Width = 250,
Anchor = Anchor.Centre,
Origin = Anchor.Centre,
- Action = () => scheduleStart(immediateGameplayState),
+ Action = () => scheduleStart(immediateSpectatorGameplayState),
Enabled = { Value = false }
}
}
@@ -167,18 +167,18 @@ namespace osu.Game.Screens.Play
showBeatmapPanel(spectatorState);
}
- protected override void StartGameplay(int userId, GameplayState gameplayState)
+ protected override void StartGameplay(int userId, SpectatorGameplayState spectatorGameplayState)
{
- immediateGameplayState = gameplayState;
+ immediateSpectatorGameplayState = spectatorGameplayState;
watchButton.Enabled.Value = true;
- scheduleStart(gameplayState);
+ scheduleStart(spectatorGameplayState);
}
protected override void EndGameplay(int userId)
{
scheduledStart?.Cancel();
- immediateGameplayState = null;
+ immediateSpectatorGameplayState = null;
watchButton.Enabled.Value = false;
clearDisplay();
@@ -194,7 +194,7 @@ namespace osu.Game.Screens.Play
private ScheduledDelegate scheduledStart;
- private void scheduleStart(GameplayState gameplayState)
+ private void scheduleStart(SpectatorGameplayState spectatorGameplayState)
{
// This function may be called multiple times in quick succession once the screen becomes current again.
scheduledStart?.Cancel();
@@ -203,15 +203,15 @@ namespace osu.Game.Screens.Play
if (this.IsCurrentScreen())
start();
else
- scheduleStart(gameplayState);
+ scheduleStart(spectatorGameplayState);
});
void start()
{
- Beatmap.Value = gameplayState.Beatmap;
- Ruleset.Value = gameplayState.Ruleset.RulesetInfo;
+ Beatmap.Value = spectatorGameplayState.Beatmap;
+ Ruleset.Value = spectatorGameplayState.Ruleset.RulesetInfo;
- this.Push(new SpectatorPlayerLoader(gameplayState.Score, () => new SoloSpectatorPlayer(gameplayState.Score)));
+ this.Push(new SpectatorPlayerLoader(spectatorGameplayState.Score, () => new SoloSpectatorPlayer(spectatorGameplayState.Score)));
}
}
diff --git a/osu.Game/Screens/Spectate/GameplayState.cs b/osu.Game/Screens/Spectate/SpectatorGameplayState.cs
similarity index 81%
rename from osu.Game/Screens/Spectate/GameplayState.cs
rename to osu.Game/Screens/Spectate/SpectatorGameplayState.cs
index 4579b9c07c..6ca1ac9a0a 100644
--- a/osu.Game/Screens/Spectate/GameplayState.cs
+++ b/osu.Game/Screens/Spectate/SpectatorGameplayState.cs
@@ -8,9 +8,9 @@ using osu.Game.Scoring;
namespace osu.Game.Screens.Spectate
{
///
- /// The gameplay state of a spectated user. This class is immutable.
+ /// An immutable spectator gameplay state.
///
- public class GameplayState
+ public class SpectatorGameplayState
{
///
/// The score which the user is playing.
@@ -27,7 +27,7 @@ namespace osu.Game.Screens.Spectate
///
public readonly WorkingBeatmap Beatmap;
- public GameplayState(Score score, Ruleset ruleset, WorkingBeatmap beatmap)
+ public SpectatorGameplayState(Score score, Ruleset ruleset, WorkingBeatmap beatmap)
{
Score = score;
Ruleset = ruleset;
diff --git a/osu.Game/Screens/Spectate/SpectatorScreen.cs b/osu.Game/Screens/Spectate/SpectatorScreen.cs
index f0a68ea078..71bcc336f3 100644
--- a/osu.Game/Screens/Spectate/SpectatorScreen.cs
+++ b/osu.Game/Screens/Spectate/SpectatorScreen.cs
@@ -43,7 +43,7 @@ namespace osu.Game.Screens.Spectate
private readonly IBindableDictionary playingUserStates = new BindableDictionary();
private readonly Dictionary userMap = new Dictionary();
- private readonly Dictionary gameplayStates = new Dictionary();
+ private readonly Dictionary gameplayStates = new Dictionary();
private IBindable> managerUpdated;
@@ -173,7 +173,7 @@ namespace osu.Game.Screens.Spectate
Replay = new Replay { HasReceivedAllFrames = false },
};
- var gameplayState = new GameplayState(score, resolvedRuleset, beatmaps.GetWorkingBeatmap(resolvedBeatmap));
+ var gameplayState = new SpectatorGameplayState(score, resolvedRuleset, beatmaps.GetWorkingBeatmap(resolvedBeatmap));
gameplayStates[userId] = gameplayState;
Schedule(() => StartGameplay(userId, gameplayState));
@@ -190,8 +190,8 @@ namespace osu.Game.Screens.Spectate
/// Starts gameplay for a user.
///
/// The user to start gameplay for.
- /// The gameplay state.
- protected abstract void StartGameplay(int userId, [NotNull] GameplayState gameplayState);
+ /// The gameplay state.
+ protected abstract void StartGameplay(int userId, [NotNull] SpectatorGameplayState spectatorGameplayState);
///
/// Ends gameplay for a user.