mirror of
https://github.com/ppy/osu
synced 2025-03-01 09:01:22 +00:00
Implements virtual Failcondition in scoreprocessor and enforces nofail in UpdateFailed
This commit is contained in:
parent
f86a13ef61
commit
9b54e834d9
@ -53,7 +53,7 @@ namespace osu.Game.Rulesets.Taiko.Scoring
|
||||
/// <summary>
|
||||
/// Taiko fails at the end of the map if the player has not half-filled their HP bar.
|
||||
/// </summary>
|
||||
public override bool HasFailed => Hits == MaxHits && Health.Value <= 0.5;
|
||||
protected override bool FailCondition => Hits == MaxHits && Health.Value <= 0.5;
|
||||
|
||||
private double hpIncreaseTick;
|
||||
private double hpIncreaseGreat;
|
||||
|
@ -69,7 +69,12 @@ namespace osu.Game.Rulesets.Scoring
|
||||
/// <summary>
|
||||
/// Whether the score is in a failed state.
|
||||
/// </summary>
|
||||
public virtual bool HasFailed => Health.Value == Health.MinValue;
|
||||
public virtual bool HasFailed => alreadyFailed;
|
||||
|
||||
/// <summary>
|
||||
/// The conditions for failing
|
||||
/// </summary>
|
||||
protected virtual bool FailCondition => Health.Value == Health.MinValue;
|
||||
|
||||
/// <summary>
|
||||
/// Whether this ScoreProcessor has already triggered the failed state.
|
||||
@ -121,7 +126,7 @@ namespace osu.Game.Rulesets.Scoring
|
||||
/// </summary>
|
||||
protected void UpdateFailed()
|
||||
{
|
||||
if (alreadyFailed || !HasFailed)
|
||||
if (alreadyFailed || !FailCondition)
|
||||
return;
|
||||
|
||||
if (Failed?.Invoke() != false)
|
||||
|
Loading…
Reference in New Issue
Block a user