Specify ScoreProcessor.Judgements.Capacity in order to avoid List<T> internal auto reallocations

This commit is contained in:
TocoToucan
2017-01-16 23:14:35 +03:00
parent b493f359b9
commit 259c0964fd
8 changed files with 14 additions and 13 deletions

View File

@ -29,11 +29,12 @@ namespace osu.Game.Modes
public readonly BindableInt HighestCombo = new BindableInt();
public readonly List<JudgementInfo> Judgements = new List<JudgementInfo>();
public readonly List<JudgementInfo> Judgements;
public ScoreProcessor()
public ScoreProcessor(int hitObjectsNumber)
{
Combo.ValueChanged += delegate { HighestCombo.Value = Math.Max(HighestCombo.Value, Combo.Value); };
Judgements = new List<JudgementInfo>(hitObjectsNumber);
}
public void AddJudgement(JudgementInfo judgement)