1
0
mirror of https://github.com/ppy/osu.git synced 2025-01-15 14:12:54 +08:00

Simplify the lookup conditions for hitcircles/sliders (uses duration to discern).

This commit is contained in:
Dean Herbert 2017-01-29 15:09:42 +09:00
parent 3125fa89ee
commit 2e76874384

View File

@ -63,8 +63,8 @@ namespace osu.Game.Screens.Select
string bpm = getBPMRange(beatmap.Beatmap);
string length = TimeSpan.FromMilliseconds((beatmap.Beatmap.HitObjects.Last().EndTime - beatmap.Beatmap.HitObjects.First().StartTime)).ToString(@"m\:ss");
string hitCircles = beatmap.Beatmap.HitObjects.Count(h => h.GetType().ToString().Equals("osu.Game.Modes.Osu.Objects.HitCircle")).ToString();
string sliders = beatmap.Beatmap.HitObjects.Count(h => h.GetType().ToString().Equals("osu.Game.Modes.Osu.Objects.Slider")).ToString();
string hitCircles = beatmap.Beatmap.HitObjects.Count(h => h.Duration == 0).ToString();
string sliders = beatmap.Beatmap.HitObjects.Count(h => h.Duration > 0).ToString();
(beatmapInfoContainer = new BufferedContainer
{