mirror of
https://github.com/ppy/osu
synced 2025-01-03 12:52:10 +00:00
Turn GenerateTicks into a bindable to pass code quality tests
This commit is contained in:
parent
9f08c474ca
commit
8f708c1dcf
@ -16,6 +16,7 @@ namespace osu.Game.Beatmaps.ControlPoints
|
||||
public static readonly DifficultyControlPoint DEFAULT = new DifficultyControlPoint
|
||||
{
|
||||
SliderVelocityBindable = { Disabled = true },
|
||||
GenerateTicksBindable = { Disabled = true },
|
||||
};
|
||||
|
||||
/// <summary>
|
||||
@ -29,6 +30,12 @@ namespace osu.Game.Beatmaps.ControlPoints
|
||||
MaxValue = 10
|
||||
};
|
||||
|
||||
/// <summary>
|
||||
/// Whether or not slider ticks should be generated at this control point.
|
||||
/// This exists for backwards compatibility with maps that abuse NaN slider velocity behavior on osu!stable (e.g. /b/2628991).
|
||||
/// </summary>
|
||||
public readonly BindableBool GenerateTicksBindable = new BindableBool(true);
|
||||
|
||||
public override Color4 GetRepresentingColour(OsuColour colours) => colours.Lime1;
|
||||
|
||||
/// <summary>
|
||||
@ -44,7 +51,11 @@ namespace osu.Game.Beatmaps.ControlPoints
|
||||
/// Whether or not slider ticks should be generated at this control point.
|
||||
/// This exists for backwards compatibility with maps that abuse NaN slider velocity behavior on osu!stable (e.g. /b/2628991).
|
||||
/// </summary>
|
||||
public bool GenerateTicks { get; set; } = true;
|
||||
public bool GenerateTicks
|
||||
{
|
||||
get => GenerateTicksBindable.Value;
|
||||
set => GenerateTicksBindable.Value = value;
|
||||
}
|
||||
|
||||
public override bool IsRedundant(ControlPoint? existing)
|
||||
=> existing is DifficultyControlPoint existingDifficulty
|
||||
|
Loading…
Reference in New Issue
Block a user