1
0
mirror of https://github.com/ppy/osu.git synced 2025-01-27 14:12:56 +08:00

Rename ColourCodedNotes to TimingBasedNoteColouring

This commit is contained in:
Justus Franklin Tumacder 2021-04-26 19:05:12 +08:00
parent 58ebec4803
commit 559d403abe
3 changed files with 8 additions and 8 deletions

View File

@ -22,7 +22,7 @@ namespace osu.Game.Rulesets.Mania.Configuration
SetDefault(ManiaRulesetSetting.ScrollTime, 1500.0, DrawableManiaRuleset.MIN_TIME_RANGE, DrawableManiaRuleset.MAX_TIME_RANGE, 5); SetDefault(ManiaRulesetSetting.ScrollTime, 1500.0, DrawableManiaRuleset.MIN_TIME_RANGE, DrawableManiaRuleset.MAX_TIME_RANGE, 5);
SetDefault(ManiaRulesetSetting.ScrollDirection, ManiaScrollingDirection.Down); SetDefault(ManiaRulesetSetting.ScrollDirection, ManiaScrollingDirection.Down);
SetDefault(ManiaRulesetSetting.ColourCodedNotes, false); SetDefault(ManiaRulesetSetting.TimingBasedNoteColouring, false);
} }
public override TrackedSettings CreateTrackedSettings() => new TrackedSettings public override TrackedSettings CreateTrackedSettings() => new TrackedSettings
@ -36,6 +36,6 @@ namespace osu.Game.Rulesets.Mania.Configuration
{ {
ScrollTime, ScrollTime,
ScrollDirection, ScrollDirection,
ColourCodedNotes TimingBasedNoteColouring
} }
} }

View File

@ -39,8 +39,8 @@ namespace osu.Game.Rulesets.Mania
}, },
new SettingsCheckbox new SettingsCheckbox
{ {
LabelText = "Colour-coded notes", LabelText = "Timing-based note colouring",
Current = config.GetBindable<bool>(ManiaRulesetSetting.ColourCodedNotes), Current = config.GetBindable<bool>(ManiaRulesetSetting.TimingBasedNoteColouring),
} }
}; };
} }

View File

@ -29,7 +29,7 @@ namespace osu.Game.Rulesets.Mania.Objects.Drawables
[Resolved] [Resolved]
private BeatDivisorFinder beatDivisorFinder { get; set; } private BeatDivisorFinder beatDivisorFinder { get; set; }
private readonly Bindable<bool> configColourCodedNotes = new Bindable<bool>(); private readonly Bindable<bool> configTimingBasedNoteColouring = new Bindable<bool>();
protected virtual ManiaSkinComponents Component => ManiaSkinComponents.Note; protected virtual ManiaSkinComponents Component => ManiaSkinComponents.Note;
@ -53,7 +53,7 @@ namespace osu.Game.Rulesets.Mania.Objects.Drawables
[BackgroundDependencyLoader(true)] [BackgroundDependencyLoader(true)]
private void load(ManiaRulesetConfigManager rulesetConfig) private void load(ManiaRulesetConfigManager rulesetConfig)
{ {
rulesetConfig?.BindWith(ManiaRulesetSetting.ColourCodedNotes, configColourCodedNotes); rulesetConfig?.BindWith(ManiaRulesetSetting.TimingBasedNoteColouring, configTimingBasedNoteColouring);
} }
protected override void LoadComplete() protected override void LoadComplete()
@ -64,7 +64,7 @@ namespace osu.Game.Rulesets.Mania.Objects.Drawables
} }
snap.BindValueChanged(_ => updateSnapColour()); snap.BindValueChanged(_ => updateSnapColour());
configColourCodedNotes.BindValueChanged(_ => updateSnapColour(), true); configTimingBasedNoteColouring.BindValueChanged(_ => updateSnapColour(), true);
} }
protected override void OnDirectionChanged(ValueChangedEvent<ScrollingDirection> e) protected override void OnDirectionChanged(ValueChangedEvent<ScrollingDirection> e)
@ -109,7 +109,7 @@ namespace osu.Game.Rulesets.Mania.Objects.Drawables
private void updateSnapColour() private void updateSnapColour()
{ {
Colour = configColourCodedNotes.Value Colour = configTimingBasedNoteColouring.Value
? BindableBeatDivisor.GetColourFor(snap.Value, colours) ? BindableBeatDivisor.GetColourFor(snap.Value, colours)
: Color4.White; : Color4.White;
} }