add HitCount enum and replace string usage with enum

This commit is contained in:
Aergwyn
2017-12-30 18:07:30 +01:00
parent d5698374f0
commit 138d78309f
9 changed files with 60 additions and 37 deletions

View File

@ -14,6 +14,7 @@ using osu.Game.Rulesets.Scoring;
using osu.Game.Users;
using System.Collections.Generic;
using osu.Framework.Graphics.Containers;
using static osu.Game.Rulesets.Scoring.Score;
namespace osu.Game.Tests.Visual
{
@ -160,9 +161,9 @@ namespace osu.Game.Tests.Visual
};
foreach(var s in scores)
{
s.Statistics.Add("300", RNG.Next(2000));
s.Statistics.Add("100", RNG.Next(2000));
s.Statistics.Add("50", RNG.Next(2000));
s.Statistics.Add(HitCount.Great, RNG.Next(2000));
s.Statistics.Add(HitCount.Good, RNG.Next(2000));
s.Statistics.Add(HitCount.Meh, RNG.Next(2000));
}
anotherScores = new[]
@ -272,9 +273,9 @@ namespace osu.Game.Tests.Visual
};
foreach (var s in anotherScores)
{
s.Statistics.Add("300", RNG.Next(2000));
s.Statistics.Add("100", RNG.Next(2000));
s.Statistics.Add("50", RNG.Next(2000));
s.Statistics.Add(HitCount.Great, RNG.Next(2000));
s.Statistics.Add(HitCount.Good, RNG.Next(2000));
s.Statistics.Add(HitCount.Meh, RNG.Next(2000));
}
topScore = new OnlineScore
@ -299,9 +300,9 @@ namespace osu.Game.Tests.Visual
TotalScore = 987654321,
Accuracy = 0.8487,
};
topScore.Statistics.Add("300", RNG.Next(2000));
topScore.Statistics.Add("100", RNG.Next(2000));
topScore.Statistics.Add("50", RNG.Next(2000));
topScore.Statistics.Add(HitCount.Great, RNG.Next(2000));
topScore.Statistics.Add(HitCount.Good, RNG.Next(2000));
topScore.Statistics.Add(HitCount.Meh, RNG.Next(2000));
}
[BackgroundDependencyLoader]