1
0
mirror of https://github.com/ppy/osu.git synced 2025-01-12 21:43:22 +08:00

Fix potential quadratic complexity in taiko autoplay

This commit is contained in:
ekrctb 2018-07-17 17:00:28 +09:00
parent fef78abdb3
commit c6816a6cf3

View File

@ -88,7 +88,8 @@ namespace osu.Game.Rulesets.Taiko.Scoring
AddJudgement(new TaikoStrongHitJudgement());
break;
case DrumRoll drumRoll:
for (int i = 0; i < drumRoll.NestedHitObjects.OfType<DrumRollTick>().Count(); i++)
var count = drumRoll.NestedHitObjects.OfType<DrumRollTick>().Count();
for (int i = 0; i < count; i++)
{
AddJudgement(new TaikoDrumRollTickJudgement { Result = HitResult.Great });