2018-01-05 19:21:19 +08:00
|
|
|
|
// Copyright (c) 2007-2018 ppy Pty Ltd <contact@ppy.sh>.
|
2017-02-07 12:59:30 +08:00
|
|
|
|
// Licensed under the MIT Licence - https://raw.githubusercontent.com/ppy/osu/master/LICENCE
|
2017-02-07 12:52:19 +08:00
|
|
|
|
|
2017-07-12 02:25:24 +08:00
|
|
|
|
using osu.Framework.Allocation;
|
2017-02-07 12:52:19 +08:00
|
|
|
|
using osu.Framework.Graphics;
|
|
|
|
|
using osu.Game.Graphics;
|
2017-05-15 09:55:29 +08:00
|
|
|
|
using osu.Game.Overlays.Settings.Sections.Gameplay;
|
2017-07-12 02:25:24 +08:00
|
|
|
|
using osu.Game.Rulesets;
|
|
|
|
|
using System.Linq;
|
2017-02-07 12:52:19 +08:00
|
|
|
|
|
2017-05-15 09:55:29 +08:00
|
|
|
|
namespace osu.Game.Overlays.Settings.Sections
|
2017-02-07 12:52:19 +08:00
|
|
|
|
{
|
2017-05-15 09:55:29 +08:00
|
|
|
|
public class GameplaySection : SettingsSection
|
2017-02-07 12:52:19 +08:00
|
|
|
|
{
|
|
|
|
|
public override string Header => "Gameplay";
|
|
|
|
|
public override FontAwesome Icon => FontAwesome.fa_circle_o;
|
|
|
|
|
|
|
|
|
|
public GameplaySection()
|
|
|
|
|
{
|
2017-02-27 22:37:38 +08:00
|
|
|
|
Children = new Drawable[]
|
2017-02-07 12:52:19 +08:00
|
|
|
|
{
|
2017-05-15 09:55:29 +08:00
|
|
|
|
new GeneralSettings(),
|
|
|
|
|
new SongSelectSettings(),
|
2018-01-08 10:34:37 +08:00
|
|
|
|
new ScrollingSettings()
|
2017-02-07 12:52:19 +08:00
|
|
|
|
};
|
|
|
|
|
}
|
2017-07-12 02:25:24 +08:00
|
|
|
|
|
|
|
|
|
[BackgroundDependencyLoader]
|
2017-07-27 15:56:41 +08:00
|
|
|
|
private void load(RulesetStore rulesets)
|
2017-07-12 02:25:24 +08:00
|
|
|
|
{
|
2017-10-16 16:02:31 +08:00
|
|
|
|
foreach(Ruleset ruleset in rulesets.AvailableRulesets.Select(info => info.CreateInstance()))
|
2017-07-12 02:25:24 +08:00
|
|
|
|
{
|
|
|
|
|
SettingsSubsection section = ruleset.CreateSettings();
|
|
|
|
|
if (section != null)
|
|
|
|
|
Add(section);
|
|
|
|
|
}
|
|
|
|
|
}
|
2017-02-07 12:52:19 +08:00
|
|
|
|
}
|
2018-01-08 10:34:37 +08:00
|
|
|
|
}
|