mirror of
https://github.com/osukey/osukey.git
synced 2025-08-04 23:24:04 +09:00
Merge pull request #15175 from peppy/fail-animation-flash-controlled-by-setting
Don't flash screen red on fail if the user has disabled red tinting
This commit is contained in:
@ -20,14 +20,15 @@ namespace osu.Game.Tests.Visual.Gameplay
|
||||
/// </summary>
|
||||
public abstract class TestSceneAllRulesetPlayers : RateAdjustedBeatmapTestScene
|
||||
{
|
||||
protected Player Player;
|
||||
protected Player Player { get; private set; }
|
||||
|
||||
protected OsuConfigManager Config { get; private set; }
|
||||
|
||||
[BackgroundDependencyLoader]
|
||||
private void load(RulesetStore rulesets)
|
||||
{
|
||||
OsuConfigManager manager;
|
||||
Dependencies.Cache(manager = new OsuConfigManager(LocalStorage));
|
||||
manager.GetBindable<double>(OsuSetting.DimLevel).Value = 1.0;
|
||||
Dependencies.Cache(Config = new OsuConfigManager(LocalStorage));
|
||||
Config.GetBindable<double>(OsuSetting.DimLevel).Value = 1.0;
|
||||
}
|
||||
|
||||
[Test]
|
||||
|
@ -2,7 +2,9 @@
|
||||
// See the LICENCE file in the repository root for full licence text.
|
||||
|
||||
using System;
|
||||
using NUnit.Framework;
|
||||
using osu.Framework.Graphics.Containers;
|
||||
using osu.Game.Configuration;
|
||||
using osu.Game.Rulesets;
|
||||
using osu.Game.Rulesets.Mods;
|
||||
using osu.Game.Screens.Play;
|
||||
@ -17,6 +19,14 @@ namespace osu.Game.Tests.Visual.Gameplay
|
||||
return new FailPlayer();
|
||||
}
|
||||
|
||||
[Test]
|
||||
public void TestOsuWithoutRedTint()
|
||||
{
|
||||
AddStep("Disable red tint", () => Config.SetValue(OsuSetting.FadePlayfieldWhenHealthLow, false));
|
||||
TestOsu();
|
||||
AddStep("Enable red tint", () => Config.SetValue(OsuSetting.FadePlayfieldWhenHealthLow, true));
|
||||
}
|
||||
|
||||
protected override void AddCheckSteps()
|
||||
{
|
||||
AddUntilStep("wait for fail", () => Player.HasFailed);
|
||||
|
Reference in New Issue
Block a user