diff --git a/osu.Game/Online/Spectator/FrameHeader.cs b/osu.Game/Online/Spectator/FrameHeader.cs
index b4988fecf9..135b356eda 100644
--- a/osu.Game/Online/Spectator/FrameHeader.cs
+++ b/osu.Game/Online/Spectator/FrameHeader.cs
@@ -14,6 +14,11 @@ namespace osu.Game.Online.Spectator
[Serializable]
public class FrameHeader
{
+ ///
+ /// The current accuracy of the score.
+ ///
+ public double Accuracy { get; set; }
+
///
/// The current combo of the score.
///
@@ -42,16 +47,18 @@ namespace osu.Game.Online.Spectator
{
Combo = score.Combo;
MaxCombo = score.MaxCombo;
+ Accuracy = score.Accuracy;
// copy for safety
Statistics = new Dictionary(score.Statistics);
}
[JsonConstructor]
- public FrameHeader(int combo, int maxCombo, Dictionary statistics, DateTimeOffset receivedTime)
+ public FrameHeader(int combo, int maxCombo, double accuracy, Dictionary statistics, DateTimeOffset receivedTime)
{
Combo = combo;
MaxCombo = maxCombo;
+ Accuracy = accuracy;
Statistics = statistics;
ReceivedTime = receivedTime;
}
diff --git a/osu.Game/Rulesets/Scoring/ScoreProcessor.cs b/osu.Game/Rulesets/Scoring/ScoreProcessor.cs
index 4b2e2bf715..2024290460 100644
--- a/osu.Game/Rulesets/Scoring/ScoreProcessor.cs
+++ b/osu.Game/Rulesets/Scoring/ScoreProcessor.cs
@@ -193,7 +193,7 @@ namespace osu.Game.Rulesets.Scoring
private void updateScore()
{
if (rollingMaxBaseScore != 0)
- Accuracy.Value = baseScore / rollingMaxBaseScore;
+ Accuracy.Value = calculateAccuracyRatio(baseScore, true);
TotalScore.Value = getScore(Mode.Value);
}
@@ -233,13 +233,13 @@ namespace osu.Game.Rulesets.Scoring
}
///
- /// Given a minimal set of inputs, return the computed score and accuracy for the tracked beatmap / mods combination, at the current point in time.
+ /// Given a minimal set of inputs, return the computed score for the tracked beatmap / mods combination, at the current point in time.
///
/// The to compute the total score in.
/// The maximum combo achievable in the beatmap.
/// Statistics to be used for calculating accuracy, bonus score, etc.
- /// The computed score and accuracy for provided inputs.
- public (double score, double accuracy) GetScoreAndAccuracy(ScoringMode mode, int maxCombo, Dictionary statistics)
+ /// The computed score for provided inputs.
+ public double GetImmediateScore(ScoringMode mode, int maxCombo, Dictionary statistics)
{
// calculate base score from statistics pairs
int computedBaseScore = 0;
@@ -252,12 +252,7 @@ namespace osu.Game.Rulesets.Scoring
computedBaseScore += Judgement.ToNumericResult(pair.Key) * pair.Value;
}
- double pointInTimeAccuracy = calculateAccuracyRatio(computedBaseScore, true);
- double comboRatio = calculateComboRatio(maxCombo);
-
- double score = GetScore(mode, maxAchievableCombo, calculateAccuracyRatio(computedBaseScore), comboRatio, scoreResultCounts);
-
- return (score, pointInTimeAccuracy);
+ return GetScore(mode, maxAchievableCombo, calculateAccuracyRatio(computedBaseScore), calculateComboRatio(maxCombo), scoreResultCounts);
}
///
diff --git a/osu.Game/Screens/Play/HUD/MultiplayerGameplayLeaderboard.cs b/osu.Game/Screens/Play/HUD/MultiplayerGameplayLeaderboard.cs
index 12321de442..c10ec9e004 100644
--- a/osu.Game/Screens/Play/HUD/MultiplayerGameplayLeaderboard.cs
+++ b/osu.Game/Screens/Play/HUD/MultiplayerGameplayLeaderboard.cs
@@ -122,8 +122,8 @@ namespace osu.Game.Screens.Play.HUD
if (LastHeader == null)
return;
- (score.Value, accuracy.Value) = processor.GetScoreAndAccuracy(mode, LastHeader.MaxCombo, LastHeader.Statistics);
-
+ score.Value = processor.GetImmediateScore(mode, LastHeader.MaxCombo, LastHeader.Statistics);
+ accuracy.Value = LastHeader.Accuracy;
currentCombo.Value = LastHeader.Combo;
}
}