1
0
mirror of https://github.com/ppy/osu.git synced 2024-11-11 09:07:52 +08:00

Add helper method to bypass judgement woes

This commit is contained in:
Dean Herbert 2024-01-16 15:52:05 +09:00
parent 24a06e1d65
commit 57a6025a2c
No known key found for this signature in database
2 changed files with 6 additions and 1 deletions

View File

@ -94,6 +94,11 @@ namespace osu.Game.Rulesets.Judgements
/// </summary>
public bool IsHit => Type.IsHit();
/// <summary>
/// The increase in health resulting from this judgement result.
/// </summary>
public double HealthIncrease => Judgement.HealthIncreaseFor(this);
/// <summary>
/// Creates a new <see cref="JudgementResult"/>.
/// </summary>

View File

@ -66,7 +66,7 @@ namespace osu.Game.Rulesets.Scoring
/// </summary>
/// <param name="result">The <see cref="JudgementResult"/>.</param>
/// <returns>The health increase.</returns>
protected virtual double GetHealthIncreaseFor(JudgementResult result) => result.Judgement.HealthIncreaseFor(result);
protected virtual double GetHealthIncreaseFor(JudgementResult result) => result.HealthIncrease;
/// <summary>
/// The default conditions for failing.