Use existing setting instead

Now it read IncreaseFirstObjectVisibility bindable instead
This commit is contained in:
Ganendra Afrasya 2019-06-09 13:11:40 +07:00
parent 8ac64b5c16
commit afc3a08953
3 changed files with 3 additions and 11 deletions

View File

@ -28,16 +28,16 @@ internal class OsuModGrow : Mod, IReadFromConfig, IApplicableToDrawableHitObject
public override double ScoreMultiplier => 1;
protected Bindable<bool> IncreaseFirstObjectGrowVisibility = new Bindable<bool>();
protected Bindable<bool> IncreaseFirstObjectVisibility = new Bindable<bool>();
public void ReadFromConfig(OsuConfigManager config)
{
IncreaseFirstObjectGrowVisibility = config.GetBindable<bool>(OsuSetting.IncreaseFirstObjectGrowVisibility);
IncreaseFirstObjectVisibility = config.GetBindable<bool>(OsuSetting.IncreaseFirstObjectVisibility);
}
public void ApplyToDrawableHitObjects(IEnumerable<DrawableHitObject> drawables)
{
foreach (var drawable in drawables.Skip(IncreaseFirstObjectGrowVisibility.Value ? 1 : 0))
foreach (var drawable in drawables.Skip(IncreaseFirstObjectVisibility.Value ? 1 : 0))
{
switch (drawable)
{

View File

@ -85,8 +85,6 @@ protected override void InitialiseDefaults()
Set(OsuSetting.IncreaseFirstObjectVisibility, true);
Set(OsuSetting.IncreaseFirstObjectGrowVisibility, true);
// Update
Set(OsuSetting.ReleaseStream, ReleaseStream.Lazer);
@ -160,7 +158,6 @@ public enum OsuSetting
BeatmapSkins,
BeatmapHitsounds,
IncreaseFirstObjectVisibility,
IncreaseFirstObjectGrowVisibility,
ScoreDisplayMode,
ExternalLinkWarning,
Scaling,

View File

@ -20,11 +20,6 @@ private void load(OsuConfigManager config)
LabelText = "Increase visibility of first object with \"Hidden\" mod",
Bindable = config.GetBindable<bool>(OsuSetting.IncreaseFirstObjectVisibility)
},
new SettingsCheckbox
{
LabelText = "Increase visibility of first object with \"Grow\" mod",
Bindable = config.GetBindable<bool>(OsuSetting.IncreaseFirstObjectGrowVisibility)
},
};
}
}