mirror of https://github.com/ppy/osu
Keep track of maximum hits + combo at base ScoreProcessor level
This commit is contained in:
parent
c7677d896a
commit
195c2d7a31
|
@ -143,6 +143,11 @@ public abstract class ScoreProcessor<TObject> : ScoreProcessor
|
|||
/// </summary>
|
||||
protected readonly List<Judgement> Judgements = new List<Judgement>();
|
||||
|
||||
private int maxHits;
|
||||
private int maxCombo;
|
||||
|
||||
private int hits;
|
||||
|
||||
protected ScoreProcessor()
|
||||
{
|
||||
}
|
||||
|
@ -154,6 +159,10 @@ protected ScoreProcessor(RulesetContainer<TObject> rulesetContainer)
|
|||
rulesetContainer.OnJudgement += AddJudgement;
|
||||
|
||||
ComputeTargets(rulesetContainer.Beatmap);
|
||||
|
||||
maxCombo = HighestCombo;
|
||||
maxHits = hits;
|
||||
|
||||
Reset();
|
||||
}
|
||||
|
||||
|
@ -173,8 +182,6 @@ protected void AddJudgement(Judgement judgement)
|
|||
{
|
||||
switch (judgement.Result)
|
||||
{
|
||||
case HitResult.None:
|
||||
break;
|
||||
case HitResult.Miss:
|
||||
Combo.Value = 0;
|
||||
break;
|
||||
|
@ -184,6 +191,9 @@ protected void AddJudgement(Judgement judgement)
|
|||
}
|
||||
}
|
||||
|
||||
if (judgement.AffectsCombo && judgement.IsHit)
|
||||
hits++;
|
||||
|
||||
Judgements.Add(judgement);
|
||||
OnNewJudgement(judgement);
|
||||
|
||||
|
|
Loading…
Reference in New Issue