1
0
mirror of https://github.com/ppy/osu.git synced 2025-01-12 21:02:54 +08:00

Ranks must be adjusted in Hidden Mod

This commit is contained in:
iiSaLMaN 2019-04-21 15:58:40 +03:00 committed by GitHub
parent 73da423639
commit 4e07975e7c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -8,10 +8,11 @@ using System.Collections.Generic;
using System.Linq;
using osu.Framework.Bindables;
using osu.Framework.Graphics.Sprites;
using osu.Game.Rulesets.Scoring;
namespace osu.Game.Rulesets.Mods
{
public abstract class ModHidden : Mod, IReadFromConfig, IApplicableToDrawableHitObjects
public abstract class ModHidden : Mod, IReadFromConfig, IApplicableToDrawableHitObjects, IApplicableToScoreProcessor
{
public override string Name => "Hidden";
public override string Acronym => "HD";
@ -31,6 +32,11 @@ namespace osu.Game.Rulesets.Mods
foreach (var d in drawables.Skip(IncreaseFirstObjectVisibility.Value ? 1 : 0))
d.ApplyCustomUpdateState += ApplyHiddenState;
}
public void ApplyToScoreProcessor(ScoreProcessor scoreProcessor)
{
scoreProcessor.AdjustRank = true;
}
protected virtual void ApplyHiddenState(DrawableHitObject hitObject, ArmedState state)
{