1
0
mirror of https://github.com/ppy/osu.git synced 2025-02-15 07:32:58 +08:00

Fix accuracy calculations.

This commit is contained in:
smoogipooo 2017-04-06 13:44:43 +09:00
parent 0acf5b45b1
commit d87a65f19e
2 changed files with 4 additions and 3 deletions

View File

@ -3,6 +3,7 @@
using osu.Game.Modes.Judgements;
using osu.Framework.Extensions;
using osu.Game.Modes.Objects.Drawables;
namespace osu.Game.Modes.Taiko.Judgements
{
@ -21,12 +22,12 @@ namespace osu.Game.Modes.Taiko.Judgements
/// <summary>
/// The result value for the combo portion of the score.
/// </summary>
public int ResultValueForScore => NumericResultForScore(TaikoResult);
public int ResultValueForScore => Result == HitResult.Miss ? 0 : NumericResultForScore(TaikoResult);
/// <summary>
/// The result value for the accuracy portion of the score.
/// </summary>
public int ResultValueForAccuracy => NumericResultForAccuracy(TaikoResult);
public int ResultValueForAccuracy => Result == HitResult.Miss ? 0 : NumericResultForAccuracy(TaikoResult);
/// <summary>
/// The maximum result value for the combo portion of the score.

View File

@ -261,7 +261,7 @@ namespace osu.Game.Modes.Taiko.Scoring
foreach (var j in Judgements)
{
scoreForAccuracy += j.ResultValueForAccuracy;
maxScoreForAccuracy = j.MaxResultValueForAccuracy;
maxScoreForAccuracy += j.MaxResultValueForAccuracy;
}
Accuracy.Value = (double)scoreForAccuracy / maxScoreForAccuracy;