1
0
mirror of https://github.com/ppy/osu.git synced 2024-11-14 16:37:26 +08:00

Actually validate judgements

This commit is contained in:
Dan Balasescu 2023-10-09 10:45:29 +09:00
parent 9415fe4446
commit 65ac617be4
No known key found for this signature in database
2 changed files with 2 additions and 4 deletions

View File

@ -91,10 +91,6 @@ namespace osu.Game.Rulesets.Judgements
}
}
public Judgement()
{
}
/// <summary>
/// The numeric score representation for the maximum achievable result.
/// </summary>

View File

@ -151,6 +151,8 @@ namespace osu.Game.Rulesets.Scoring
{
var judgement = obj.CreateJudgement();
HitResultExtensions.ValidateHitResultPair(judgement.MaxResult, judgement.MinResult);
var result = CreateResult(obj, judgement);
if (result == null)
throw new InvalidOperationException($"{GetType().ReadableName()} must provide a {nameof(JudgementResult)} through {nameof(CreateResult)}.");