mirror of
https://github.com/ppy/osu.git
synced 2025-01-12 11:42:54 +08:00
change hitlighting bool to bindable
This commit is contained in:
parent
a25f4880d6
commit
3e2d184a91
@ -5,6 +5,7 @@ using System;
|
||||
using System.Linq;
|
||||
using JetBrains.Annotations;
|
||||
using osu.Framework.Allocation;
|
||||
using osu.Framework.Bindables;
|
||||
using osu.Framework.Graphics;
|
||||
using osu.Framework.Graphics.Animations;
|
||||
using osu.Framework.Graphics.Containers;
|
||||
@ -100,7 +101,7 @@ namespace osu.Game.Rulesets.Catch.UI
|
||||
private double hyperDashModifier = 1;
|
||||
private int hyperDashDirection;
|
||||
private float hyperDashTargetPosition;
|
||||
private bool hitLighting;
|
||||
private Bindable<bool> hitLighting;
|
||||
|
||||
public Catcher([NotNull] Container trailsTarget, BeatmapDifficulty difficulty = null)
|
||||
{
|
||||
@ -118,7 +119,7 @@ namespace osu.Game.Rulesets.Catch.UI
|
||||
[BackgroundDependencyLoader]
|
||||
private void load(OsuConfigManager config)
|
||||
{
|
||||
hitLighting = config.Get<bool>(OsuSetting.HitLighting);
|
||||
hitLighting = config.GetBindable<bool>(OsuSetting.HitLighting);
|
||||
|
||||
InternalChildren = new Drawable[]
|
||||
{
|
||||
@ -193,7 +194,7 @@ namespace osu.Game.Rulesets.Catch.UI
|
||||
|
||||
caughtFruit.Add(fruit);
|
||||
|
||||
if (hitLighting)
|
||||
if (hitLighting.Value)
|
||||
{
|
||||
AddInternal(new HitExplosion(fruit)
|
||||
{
|
||||
|
Loading…
Reference in New Issue
Block a user