mirror of
https://github.com/ppy/osu
synced 2025-01-11 08:39:31 +00:00
add setting to toggle the gameplay cursor trail
This commit is contained in:
parent
4d310c3226
commit
481f33d17b
@ -19,12 +19,14 @@ namespace osu.Game.Rulesets.Osu.Configuration
|
||||
|
||||
Set(OsuSetting.SnakingInSliders, true);
|
||||
Set(OsuSetting.SnakingOutSliders, true);
|
||||
Set(OsuSetting.ShowCursorTrail, true);
|
||||
}
|
||||
}
|
||||
|
||||
public enum OsuSetting
|
||||
{
|
||||
SnakingInSliders,
|
||||
SnakingOutSliders
|
||||
SnakingOutSliders,
|
||||
ShowCursorTrail
|
||||
}
|
||||
}
|
||||
|
@ -11,6 +11,7 @@ using osu.Framework.Graphics.Shapes;
|
||||
using osu.Framework.Input.Bindings;
|
||||
using osu.Game.Beatmaps;
|
||||
using osu.Game.Configuration;
|
||||
using osu.Game.Rulesets.Osu.Configuration;
|
||||
using osu.Game.Skinning;
|
||||
using osuTK;
|
||||
using osuTK.Graphics;
|
||||
@ -23,6 +24,8 @@ namespace osu.Game.Rulesets.Osu.UI.Cursor
|
||||
|
||||
protected override Container<Drawable> Content => fadeContainer;
|
||||
|
||||
private Bindable<bool> showTrail;
|
||||
private readonly CursorTrail cursorTrail;
|
||||
private readonly Container<Drawable> fadeContainer;
|
||||
|
||||
public GameplayCursor()
|
||||
@ -32,11 +35,18 @@ namespace osu.Game.Rulesets.Osu.UI.Cursor
|
||||
RelativeSizeAxes = Axes.Both,
|
||||
Children = new Drawable[]
|
||||
{
|
||||
new CursorTrail { Depth = 1 }
|
||||
cursorTrail = new CursorTrail { Depth = 1 }
|
||||
}
|
||||
};
|
||||
}
|
||||
|
||||
[BackgroundDependencyLoader]
|
||||
private void load(OsuConfigManager config)
|
||||
{
|
||||
showTrail = config.GetBindable<bool>(OsuSetting.ShowCursorTrail);
|
||||
showTrail.ValueChanged += v => cursorTrail.Alpha = v ? 1 : 0;
|
||||
}
|
||||
|
||||
private int downCount;
|
||||
|
||||
private void updateExpandedState()
|
||||
|
@ -34,6 +34,11 @@ namespace osu.Game.Rulesets.Osu.UI
|
||||
LabelText = "Snaking out sliders",
|
||||
Bindable = config.GetBindable<bool>(OsuSetting.SnakingOutSliders)
|
||||
},
|
||||
new SettingsCheckbox
|
||||
{
|
||||
LabelText = "Show cursor trail",
|
||||
Bindable = config.GetBindable<bool>(OsuSetting.ShowCursorTrail)
|
||||
},
|
||||
};
|
||||
}
|
||||
}
|
||||
|
@ -72,9 +72,6 @@ namespace osu.Game.Configuration
|
||||
|
||||
Set(GameSetting.MenuParallax, true);
|
||||
|
||||
Set(GameSetting.SnakingInSliders, true);
|
||||
Set(GameSetting.SnakingOutSliders, true);
|
||||
|
||||
// Gameplay
|
||||
Set(GameSetting.DimLevel, 0.3, 0, 1, 0.01);
|
||||
Set(GameSetting.BlurLevel, 0, 0, 1, 0.01);
|
||||
@ -150,8 +147,6 @@ namespace osu.Game.Configuration
|
||||
DisplayStarsMinimum,
|
||||
DisplayStarsMaximum,
|
||||
RandomSelectAlgorithm,
|
||||
SnakingInSliders,
|
||||
SnakingOutSliders,
|
||||
ShowFpsDisplay,
|
||||
ChatDisplayHeight,
|
||||
Version,
|
||||
|
Loading…
Reference in New Issue
Block a user