2020-04-17 07:32:12 +00:00
|
|
|
|
// Copyright (c) ppy Pty Ltd <contact@ppy.sh>. Licensed under the MIT Licence.
|
|
|
|
|
// See the LICENCE file in the repository root for full licence text.
|
|
|
|
|
|
2023-03-27 16:08:06 +00:00
|
|
|
|
using osu.Framework.Extensions.ObjectExtensions;
|
|
|
|
|
using osu.Game.Rulesets.Mania.Configuration;
|
|
|
|
|
using osu.Game.Rulesets.Mania.UI;
|
2020-04-17 07:32:12 +00:00
|
|
|
|
using osu.Game.Tests.Visual;
|
|
|
|
|
|
|
|
|
|
namespace osu.Game.Rulesets.Mania.Tests
|
|
|
|
|
{
|
|
|
|
|
public partial class TestSceneManiaPlayer : PlayerTestScene
|
|
|
|
|
{
|
2020-04-23 10:25:06 +00:00
|
|
|
|
protected override Ruleset CreatePlayerRuleset() => new ManiaRuleset();
|
2023-03-27 16:08:06 +00:00
|
|
|
|
|
|
|
|
|
public override void SetUpSteps()
|
|
|
|
|
{
|
|
|
|
|
base.SetUpSteps();
|
|
|
|
|
|
|
|
|
|
AddStep("change direction to down", () => changeDirectionTo(ManiaScrollingDirection.Down));
|
|
|
|
|
AddStep("change direction to up", () => changeDirectionTo(ManiaScrollingDirection.Up));
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
private void changeDirectionTo(ManiaScrollingDirection direction)
|
|
|
|
|
{
|
|
|
|
|
var rulesetConfig = (ManiaRulesetConfigManager)RulesetConfigs.GetConfigFor(new ManiaRuleset()).AsNonNull();
|
|
|
|
|
rulesetConfig.SetValue(ManiaRulesetSetting.ScrollDirection, direction);
|
|
|
|
|
}
|
2020-04-17 07:32:12 +00:00
|
|
|
|
}
|
|
|
|
|
}
|