Move IGameplaySettings override to compose screen to keep test mode unaffected

This commit is contained in:
Salman Ahmed
2022-11-17 01:32:54 +03:00
parent ee6fffec5f
commit 7a28a7f2a0
4 changed files with 15 additions and 30 deletions

View File

@ -11,6 +11,7 @@ using osu.Framework.Graphics;
using osu.Framework.Graphics.Containers;
using osu.Framework.Platform;
using osu.Game.Beatmaps;
using osu.Game.Configuration;
using osu.Game.Extensions;
using osu.Game.IO.Serialization;
using osu.Game.Rulesets;
@ -19,7 +20,7 @@ using osu.Game.Screens.Edit.Compose.Components.Timeline;
namespace osu.Game.Screens.Edit.Compose
{
public class ComposeScreen : EditorScreenWithTimeline
public class ComposeScreen : EditorScreenWithTimeline, IGameplaySettings
{
[Resolved]
private GameHost host { get; set; }
@ -27,6 +28,9 @@ namespace osu.Game.Screens.Edit.Compose
[Resolved]
private EditorClock clock { get; set; }
[Resolved]
private IGameplaySettings globalGameplaySettings { get; set; }
private Bindable<string> clipboard { get; set; }
private HitObjectComposer composer;
@ -157,5 +161,12 @@ namespace osu.Game.Screens.Edit.Compose
}
#endregion
// Combo colour normalisation should not be applied in the editor.
// Note this doesn't affect editor test mode.
IBindable<float> IGameplaySettings.ComboColourNormalisationAmount => new Bindable<float>();
// Arguable.
IBindable<float> IGameplaySettings.PositionalHitsoundsLevel => globalGameplaySettings.PositionalHitsoundsLevel;
}
}