mirror of
https://github.com/ppy/osu.git
synced 2025-01-16 03:42:55 +08:00
commit
71045169f6
@ -1 +1 @@
|
|||||||
Subproject commit 92b49515eeae2f6a7c96247b8c3eda97e5514780
|
Subproject commit 2b9a56e8b3bb6c99bf4c75307639e6726fe8d3ec
|
@ -1 +1 @@
|
|||||||
Subproject commit ca807cf81ae3706972937d4e1009376cfaa0b266
|
Subproject commit c0781d1d557c3e5a00f6cf1780049e382f92c0c8
|
25
osu.Desktop.VisualTests/OpenTK.dll.config
Normal file
25
osu.Desktop.VisualTests/OpenTK.dll.config
Normal file
@ -0,0 +1,25 @@
|
|||||||
|
<configuration>
|
||||||
|
<dllmap os="linux" dll="opengl32.dll" target="libGL.so.1"/>
|
||||||
|
<dllmap os="linux" dll="glu32.dll" target="libGLU.so.1"/>
|
||||||
|
<dllmap os="linux" dll="openal32.dll" target="libopenal.so.1"/>
|
||||||
|
<dllmap os="linux" dll="alut.dll" target="libalut.so.0"/>
|
||||||
|
<dllmap os="linux" dll="opencl.dll" target="libOpenCL.so"/>
|
||||||
|
<dllmap os="linux" dll="libX11" target="libX11.so.6"/>
|
||||||
|
<dllmap os="linux" dll="libXi" target="libXi.so.6"/>
|
||||||
|
<dllmap os="linux" dll="SDL2.dll" target="libSDL2-2.0.so.0"/>
|
||||||
|
<dllmap os="osx" dll="opengl32.dll" target="/System/Library/Frameworks/OpenGL.framework/OpenGL"/>
|
||||||
|
<dllmap os="osx" dll="openal32.dll" target="/System/Library/Frameworks/OpenAL.framework/OpenAL" />
|
||||||
|
<dllmap os="osx" dll="alut.dll" target="/System/Library/Frameworks/OpenAL.framework/OpenAL" />
|
||||||
|
<dllmap os="osx" dll="libGLES.dll" target="/System/Library/Frameworks/OpenGLES.framework/OpenGLES" />
|
||||||
|
<dllmap os="osx" dll="libGLESv1_CM.dll" target="/System/Library/Frameworks/OpenGLES.framework/OpenGLES" />
|
||||||
|
<dllmap os="osx" dll="libGLESv2.dll" target="/System/Library/Frameworks/OpenGLES.framework/OpenGLES" />
|
||||||
|
<dllmap os="osx" dll="opencl.dll" target="/System/Library/Frameworks/OpenCL.framework/OpenCL"/>
|
||||||
|
<dllmap os="osx" dll="SDL2.dll" target="libSDL2.dylib"/>
|
||||||
|
<!-- XQuartz compatibility (X11 on Mac) -->
|
||||||
|
<dllmap os="osx" dll="libGL.so.1" target="/usr/X11/lib/libGL.dylib"/>
|
||||||
|
<dllmap os="osx" dll="libX11" target="/usr/X11/lib/libX11.dylib"/>
|
||||||
|
<dllmap os="osx" dll="libXcursor.so.1" target="/usr/X11/lib/libXcursor.dylib"/>
|
||||||
|
<dllmap os="osx" dll="libXi" target="/usr/X11/lib/libXi.dylib"/>
|
||||||
|
<dllmap os="osx" dll="libXinerama" target="/usr/X11/lib/libXinerama.dylib"/>
|
||||||
|
<dllmap os="osx" dll="libXrandr.so.2" target="/usr/X11/lib/libXrandr.dylib"/>
|
||||||
|
</configuration>
|
29
osu.Desktop.VisualTests/Tests/TestCaseOptions.cs
Normal file
29
osu.Desktop.VisualTests/Tests/TestCaseOptions.cs
Normal file
@ -0,0 +1,29 @@
|
|||||||
|
//Copyright (c) 2007-2016 ppy Pty Ltd <contact@ppy.sh>.
|
||||||
|
//Licensed under the MIT Licence - https://raw.githubusercontent.com/ppy/osu/master/LICENCE
|
||||||
|
|
||||||
|
using osu.Framework.GameModes.Testing;
|
||||||
|
using osu.Framework.Graphics;
|
||||||
|
using osu.Game.Graphics.UserInterface;
|
||||||
|
using OpenTK.Input;
|
||||||
|
using osu.Game.Overlays;
|
||||||
|
using osu.Framework.Graphics.Containers;
|
||||||
|
|
||||||
|
namespace osu.Desktop.VisualTests.Tests
|
||||||
|
{
|
||||||
|
class TestCaseOptions : TestCase
|
||||||
|
{
|
||||||
|
public override string Name => @"Options";
|
||||||
|
|
||||||
|
public override string Description => @"Tests the options overlay";
|
||||||
|
|
||||||
|
private OptionsOverlay options;
|
||||||
|
|
||||||
|
public override void Reset()
|
||||||
|
{
|
||||||
|
base.Reset();
|
||||||
|
|
||||||
|
Children = new[] { options = new OptionsOverlay() };
|
||||||
|
options.ToggleVisibility();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
@ -80,13 +80,9 @@
|
|||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<Reference Include="mscorlib" />
|
<Reference Include="mscorlib" />
|
||||||
<Reference Include="OpenTK, Version=2.0.0.0, Culture=neutral, PublicKeyToken=bad199fe84eb3df4, processorArchitecture=MSIL">
|
|
||||||
<HintPath>$(SolutionDir)\packages\ppy.OpenTK.2.0.50727.1337\lib\net20\OpenTK.dll</HintPath>
|
|
||||||
<Private>True</Private>
|
|
||||||
</Reference>
|
|
||||||
<Reference Include="SQLite.Net, Version=3.1.0.0, Culture=neutral, processorArchitecture=MSIL">
|
<Reference Include="SQLite.Net, Version=3.1.0.0, Culture=neutral, processorArchitecture=MSIL">
|
||||||
<SpecificVersion>False</SpecificVersion>
|
<SpecificVersion>False</SpecificVersion>
|
||||||
<HintPath>..\packages\SQLite.Net.Core-PCL.3.1.1\lib\portable-win8+net45+wp8+wpa81+MonoAndroid1+MonoTouch1\SQLite.Net.dll</HintPath>
|
<HintPath>$(SolutionDir)\packages\SQLite.Net.Core-PCL.3.1.1\lib\portable-win8+net45+wp8+wpa81+MonoAndroid1+MonoTouch1\SQLite.Net.dll</HintPath>
|
||||||
</Reference>
|
</Reference>
|
||||||
<Reference Include="System" />
|
<Reference Include="System" />
|
||||||
<Reference Include="Newtonsoft.Json">
|
<Reference Include="Newtonsoft.Json">
|
||||||
@ -101,12 +97,18 @@
|
|||||||
<Reference Include="SQLite.Net.Platform.Generic">
|
<Reference Include="SQLite.Net.Platform.Generic">
|
||||||
<HintPath>$(SolutionDir)\packages\SQLite.Net-PCL.3.1.1\lib\net40\SQLite.Net.Platform.Generic.dll</HintPath>
|
<HintPath>$(SolutionDir)\packages\SQLite.Net-PCL.3.1.1\lib\net40\SQLite.Net.Platform.Generic.dll</HintPath>
|
||||||
</Reference>
|
</Reference>
|
||||||
|
<Reference Include="OpenTK">
|
||||||
|
<HintPath>$(SolutionDir)\packages\ppy.OpenTK.2.0.50727.1339\lib\net45\OpenTK.dll</HintPath>
|
||||||
|
</Reference>
|
||||||
|
<Reference Include="System.Drawing" />
|
||||||
|
<Reference Include="System.Xml" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<None Include="..\osu.licenseheader">
|
<None Include="..\osu.licenseheader">
|
||||||
<Link>osu.licenseheader</Link>
|
<Link>osu.licenseheader</Link>
|
||||||
</None>
|
</None>
|
||||||
<None Include="packages.config" />
|
<None Include="packages.config" />
|
||||||
|
<None Include="OpenTK.dll.config" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<BootstrapperPackage Include="Microsoft.Net.Client.3.5">
|
<BootstrapperPackage Include="Microsoft.Net.Client.3.5">
|
||||||
@ -166,6 +168,7 @@
|
|||||||
<Compile Include="Tests\TestCasePlaySongSelect.cs" />
|
<Compile Include="Tests\TestCasePlaySongSelect.cs" />
|
||||||
<Compile Include="VisualTestGame.cs" />
|
<Compile Include="VisualTestGame.cs" />
|
||||||
<Compile Include="Platform\TestStorage.cs" />
|
<Compile Include="Platform\TestStorage.cs" />
|
||||||
|
<Compile Include="Tests\TestCaseOptions.cs" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
<ItemGroup />
|
<ItemGroup />
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
|
@ -1,6 +1,7 @@
|
|||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<packages>
|
<packages>
|
||||||
<package id="Newtonsoft.Json" version="9.0.1" targetFramework="net45" />
|
<package id="Newtonsoft.Json" version="9.0.1" targetFramework="net45" />
|
||||||
|
<package id="ppy.OpenTK" version="2.0.50727.1339" targetFramework="net45" />
|
||||||
<package id="SQLite.Net.Core-PCL" version="3.1.1" targetFramework="net45" />
|
<package id="SQLite.Net.Core-PCL" version="3.1.1" targetFramework="net45" />
|
||||||
<package id="SQLite.Net-PCL" version="3.1.1" targetFramework="net45" />
|
<package id="SQLite.Net-PCL" version="3.1.1" targetFramework="net45" />
|
||||||
<package id="SQLiteNetExtensions" version="1.3.0" targetFramework="net45" />
|
<package id="SQLiteNetExtensions" version="1.3.0" targetFramework="net45" />
|
||||||
|
@ -2,6 +2,7 @@
|
|||||||
//Licensed under the MIT Licence - https://raw.githubusercontent.com/ppy/osu/master/LICENCE
|
//Licensed under the MIT Licence - https://raw.githubusercontent.com/ppy/osu/master/LICENCE
|
||||||
|
|
||||||
using osu.Framework.Configuration;
|
using osu.Framework.Configuration;
|
||||||
|
using osu.Framework.Platform;
|
||||||
using osu.Game.GameModes.Play;
|
using osu.Game.GameModes.Play;
|
||||||
using osu.Game.Online.API;
|
using osu.Game.Online.API;
|
||||||
|
|
||||||
@ -13,7 +14,7 @@ namespace osu.Game.Configuration
|
|||||||
{
|
{
|
||||||
Set(OsuConfig.Width, 1366, 640);
|
Set(OsuConfig.Width, 1366, 640);
|
||||||
Set(OsuConfig.Height, 768, 480);
|
Set(OsuConfig.Height, 768, 480);
|
||||||
Set(OsuConfig.MouseSensitivity, 1.0);
|
Set(OsuConfig.MouseSpeed, 1.0);
|
||||||
|
|
||||||
Set(OsuConfig.Username, string.Empty);
|
Set(OsuConfig.Username, string.Empty);
|
||||||
Set(OsuConfig.Password, string.Empty);
|
Set(OsuConfig.Password, string.Empty);
|
||||||
@ -21,23 +22,314 @@ namespace osu.Game.Configuration
|
|||||||
|
|
||||||
Set(OsuConfig.PlayMode, PlayMode.Osu);
|
Set(OsuConfig.PlayMode, PlayMode.Osu);
|
||||||
|
|
||||||
Set(OsuConfig.VolumeGlobal, 0.8, 0, 1);
|
Set(OsuConfig.BeatmapDirectory, @"Songs"); // TODO: use this
|
||||||
|
|
||||||
|
Set(OsuConfig.VolumeUniversal, 0.8, 0, 1);
|
||||||
Set(OsuConfig.VolumeMusic, 1.0, 0, 1);
|
Set(OsuConfig.VolumeMusic, 1.0, 0, 1);
|
||||||
Set(OsuConfig.VolumeEffect, 1.0, 0, 1);
|
Set(OsuConfig.VolumeEffect, 1.0, 0, 1);
|
||||||
|
|
||||||
|
Set(OsuConfig.AllowPublicInvites, true);
|
||||||
|
Set(OsuConfig.AutoChatHide, true);
|
||||||
|
Set(OsuConfig.AutomaticDownload, true);
|
||||||
|
Set(OsuConfig.AutomaticDownloadNoVideo, false);
|
||||||
|
Set(OsuConfig.BlockNonFriendPM, false);
|
||||||
|
Set(OsuConfig.BloomSoftening, false);
|
||||||
|
Set(OsuConfig.BossKeyFirstActivation, true);
|
||||||
|
Set(OsuConfig.ChatAudibleHighlight, true);
|
||||||
|
Set(OsuConfig.ChatChannels, string.Empty);
|
||||||
|
Set(OsuConfig.ChatFilter, false);
|
||||||
|
Set(OsuConfig.ChatHighlightName, true);
|
||||||
|
Set(OsuConfig.ChatMessageNotification, true);
|
||||||
|
Set(OsuConfig.ChatLastChannel, string.Empty);
|
||||||
|
Set(OsuConfig.ChatRemoveForeign, false);
|
||||||
|
//Set(OsuConfig.ChatSortMode, UserSortMode.Rank);
|
||||||
|
Set(OsuConfig.ComboBurst, true);
|
||||||
|
Set(OsuConfig.ComboFire, false);
|
||||||
|
Set(OsuConfig.ComboFireHeight, 3);
|
||||||
|
Set(OsuConfig.ConfirmExit, false);
|
||||||
|
Set(OsuConfig.AutoSendNowPlaying, true);
|
||||||
|
Set(OsuConfig.CursorSize, 1.0, 0.5f, 2);
|
||||||
|
Set(OsuConfig.AutomaticCursorSizing, false);
|
||||||
|
Set(OsuConfig.DimLevel, 30, 0, 100);
|
||||||
|
Set(OsuConfig.Display, 1);
|
||||||
|
Set(OsuConfig.DisplayCityLocation, false);
|
||||||
|
Set(OsuConfig.DistanceSpacingEnabled, true);
|
||||||
|
Set(OsuConfig.EditorTip, 0);
|
||||||
|
Set(OsuConfig.VideoEditor, Get<bool>(OsuConfig.Fullscreen));
|
||||||
|
Set(OsuConfig.EditorDefaultSkin, false);
|
||||||
|
Set(OsuConfig.EditorSnakingSliders, true);
|
||||||
|
Set(OsuConfig.EditorHitAnimations, false);
|
||||||
|
Set(OsuConfig.EditorFollowPoints, true);
|
||||||
|
Set(OsuConfig.EditorStacking, true);
|
||||||
|
Set(OsuConfig.ForceSliderRendering, false);
|
||||||
|
Set(OsuConfig.FpsCounter, false);
|
||||||
|
Set(OsuConfig.FrameTimeDisplay, false);
|
||||||
|
Set(OsuConfig.GuideTips, @"");
|
||||||
|
Set(OsuConfig.CursorRipple, false);
|
||||||
|
Set(OsuConfig.HighlightWords, string.Empty);
|
||||||
|
Set(OsuConfig.HighResolution, false);
|
||||||
|
Set(OsuConfig.HitLighting, true);
|
||||||
|
Set(OsuConfig.IgnoreBarline, false);
|
||||||
|
Set(OsuConfig.IgnoreBeatmapSamples, false);
|
||||||
|
Set(OsuConfig.IgnoreBeatmapSkins, false);
|
||||||
|
Set(OsuConfig.IgnoreList, string.Empty);
|
||||||
|
Set(OsuConfig.KeyOverlay, false);
|
||||||
|
Set(OsuConfig.Language, @"unknown");
|
||||||
|
Set(OsuConfig.AllowNowPlayingHighlights, false);
|
||||||
|
Set(OsuConfig.LastVersion, string.Empty);
|
||||||
|
Set(OsuConfig.LastVersionPermissionsFailed, string.Empty);
|
||||||
|
Set(OsuConfig.LoadSubmittedThread, true);
|
||||||
|
Set(OsuConfig.LobbyPlayMode, -1);
|
||||||
|
Set(OsuConfig.ShowInterface, true);
|
||||||
|
Set(OsuConfig.ShowInterfaceDuringRelax, false);
|
||||||
|
Set(OsuConfig.LobbyShowExistingOnly, false);
|
||||||
|
Set(OsuConfig.LobbyShowFriendsOnly, false);
|
||||||
|
Set(OsuConfig.LobbyShowFull, false);
|
||||||
|
Set(OsuConfig.LobbyShowInProgress, true);
|
||||||
|
Set(OsuConfig.LobbyShowPassworded, true);
|
||||||
|
Set(OsuConfig.LogPrivateMessages, false);
|
||||||
|
Set(OsuConfig.LowResolution, false);
|
||||||
|
//Set(OsuConfig.ManiaSpeed, SpeedMania.SPEED_DEFAULT, SpeedMania.SPEED_MIN, SpeedMania.SPEED_MAX);
|
||||||
|
Set(OsuConfig.UsePerBeatmapManiaSpeed, true);
|
||||||
|
Set(OsuConfig.ManiaSpeedBPMScale, true);
|
||||||
|
Set(OsuConfig.MenuTip, 0);
|
||||||
|
Set(OsuConfig.MouseDisableButtons, false);
|
||||||
|
Set(OsuConfig.MouseDisableWheel, false);
|
||||||
|
Set(OsuConfig.MouseSpeed, 1, 0.4, 6);
|
||||||
|
Set(OsuConfig.Offset, 0, -300, 300);
|
||||||
|
//Set(OsuConfig.ScoreMeterScale, 1, 0.5, OsuGame.Tournament ? 10 : 2);
|
||||||
|
Set(OsuConfig.DistanceSpacing, 0.8, 0.1, 6);
|
||||||
|
Set(OsuConfig.EditorBeatDivisor, 1, 1, 16);
|
||||||
|
Set(OsuConfig.EditorGridSize, 32, 4, 32);
|
||||||
|
Set(OsuConfig.EditorGridSizeDesign, 32, 4, 32);
|
||||||
|
Set(OsuConfig.HeightFullscreen, 9999, 240, 9999);
|
||||||
|
Set(OsuConfig.CustomFrameLimit, 240, 240, 999);
|
||||||
|
Set(OsuConfig.WidthFullscreen, 9999, 320, 9999);
|
||||||
|
Set(OsuConfig.MsnIntegration, false);
|
||||||
|
Set(OsuConfig.MyPcSucks, false);
|
||||||
|
Set(OsuConfig.NotifyFriends, true);
|
||||||
|
Set(OsuConfig.NotifySubmittedThread, true);
|
||||||
|
Set(OsuConfig.PopupDuringGameplay, true);
|
||||||
|
//Set(OsuConfig.ProgressBarType, ProgressBarTypes.Pie);
|
||||||
|
//Set(OsuConfig.RankType, RankingType.Top);
|
||||||
|
Set(OsuConfig.RefreshRate, 60);
|
||||||
|
Set(OsuConfig.OverrideRefreshRate, Get<int>(OsuConfig.RefreshRate) != 60);
|
||||||
|
//Set(OsuConfig.ScaleMode, ScaleMode.WidescreenConservative);
|
||||||
|
Set(OsuConfig.ScoreboardVisible, true);
|
||||||
|
//Set(OsuConfig.ScoreMeter, OsuGame.Tournament ? ScoreMeterType.Colour : ScoreMeterType.Error);
|
||||||
|
Set(OsuConfig.ScreenshotId, 0);
|
||||||
|
Set(OsuConfig.MenuSnow, false);
|
||||||
|
Set(OsuConfig.MenuTriangles, true);
|
||||||
|
Set(OsuConfig.SongSelectThumbnails, true);
|
||||||
|
//Set(OsuConfig.ScreenshotFormat, ImageFileFormat.Jpg);
|
||||||
|
Set(OsuConfig.ShowReplayComments, true);
|
||||||
|
Set(OsuConfig.ShowSpectators, true);
|
||||||
|
Set(OsuConfig.ShowStoryboard, true);
|
||||||
|
//Set(OsuConfig.Skin, SkinManager.DEFAULT_SKIN);
|
||||||
|
Set(OsuConfig.SkinSamples, true);
|
||||||
|
Set(OsuConfig.SkipTablet, false);
|
||||||
|
Set(OsuConfig.SnakingSliders, true);
|
||||||
|
Set(OsuConfig.Tablet, false);
|
||||||
|
Set(OsuConfig.UpdatePending, false);
|
||||||
|
Set(OsuConfig.UseSkinCursor, false);
|
||||||
|
Set(OsuConfig.UseTaikoSkin, false);
|
||||||
|
Set(OsuConfig.Video, true);
|
||||||
|
Set(OsuConfig.Wiimote, false);
|
||||||
|
Set(OsuConfig.YahooIntegration, false);
|
||||||
|
Set(OsuConfig.ForceFrameFlush, false);
|
||||||
|
Set(OsuConfig.DetectPerformanceIssues, true);
|
||||||
|
Set(OsuConfig.Fullscreen, true);
|
||||||
|
Set(OsuConfig.MenuMusic, true);
|
||||||
|
Set(OsuConfig.MenuVoice, true);
|
||||||
|
Set(OsuConfig.MenuParallax, true);
|
||||||
|
Set(OsuConfig.RawInput, false);
|
||||||
|
Set(OsuConfig.AbsoluteToOsuWindow, Get<bool>(OsuConfig.RawInput));
|
||||||
|
Set(OsuConfig.ShowMenuTips, true);
|
||||||
|
Set(OsuConfig.HiddenShowFirstApproach, true);
|
||||||
|
Set(OsuConfig.ComboColourSliderBall, true);
|
||||||
|
Set(OsuConfig.AlternativeChatFont, false);
|
||||||
|
Set(OsuConfig.Password, string.Empty);
|
||||||
|
Set(OsuConfig.Username, string.Empty);
|
||||||
|
Set(OsuConfig.DisplayStarsMaximum, 10, 0, 10);
|
||||||
|
Set(OsuConfig.DisplayStarsMinimum, 0, 0, 10);
|
||||||
|
Set(OsuConfig.AudioDevice, string.Empty);
|
||||||
|
//Set(OsuConfig.ReleaseStream, ReleaseStream.Lazer, true);
|
||||||
|
Set(OsuConfig.UpdateFailCount, 0);
|
||||||
|
//Set(OsuConfig.SavePassword, Password != null);
|
||||||
|
Set(OsuConfig.SaveUsername, true);
|
||||||
|
//Set(OsuConfig.TreeSortMode, TreeGroupMode.Show_All);
|
||||||
|
//Set(OsuConfig.TreeSortMode2, TreeSortMode.Title);
|
||||||
|
Set(OsuConfig.Letterboxing, Get<bool>(OsuConfig.Fullscreen));
|
||||||
|
Set(OsuConfig.LetterboxPositionX, 0, -100, 100);
|
||||||
|
Set(OsuConfig.LetterboxPositionY, 0, -100, 100);
|
||||||
|
//Set(OsuConfig.FrameSync, FrameSync.Limit120);
|
||||||
|
//Set(OsuConfig.ShowUnicode, unicodeDefault);
|
||||||
|
Set(OsuConfig.PermanentSongInfo, false);
|
||||||
|
Set(OsuConfig.Ticker, false);
|
||||||
|
Set(OsuConfig.CompatibilityContext, false);
|
||||||
|
Set(OsuConfig.CanForceOptimusCompatibility, true);
|
||||||
|
}
|
||||||
|
|
||||||
|
public OsuConfigManager(BasicStorage storage) : base(storage)
|
||||||
|
{
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
enum OsuConfig
|
enum OsuConfig
|
||||||
{
|
{
|
||||||
Width,
|
// New osu:
|
||||||
Height,
|
|
||||||
MouseSensitivity,
|
|
||||||
Username,
|
|
||||||
Password,
|
|
||||||
Token,
|
|
||||||
PlayMode,
|
PlayMode,
|
||||||
VolumeGlobal,
|
Token,
|
||||||
|
// Imported from old osu:
|
||||||
|
BeatmapDirectory,
|
||||||
|
VolumeUniversal,
|
||||||
VolumeEffect,
|
VolumeEffect,
|
||||||
VolumeMusic
|
VolumeMusic,
|
||||||
|
AllowPublicInvites,
|
||||||
|
AutoChatHide,
|
||||||
|
AutomaticDownload,
|
||||||
|
AutomaticDownloadNoVideo,
|
||||||
|
BlockNonFriendPM,
|
||||||
|
Bloom,
|
||||||
|
BloomSoftening,
|
||||||
|
BossKeyFirstActivation,
|
||||||
|
ChatAudibleHighlight,
|
||||||
|
ChatChannels,
|
||||||
|
ChatFilter,
|
||||||
|
ChatHighlightName,
|
||||||
|
ChatMessageNotification,
|
||||||
|
ChatLastChannel,
|
||||||
|
ChatRemoveForeign,
|
||||||
|
ChatSortMode,
|
||||||
|
ComboBurst,
|
||||||
|
ComboFire,
|
||||||
|
ComboFireHeight,
|
||||||
|
ConfirmExit,
|
||||||
|
AutoSendNowPlaying,
|
||||||
|
CursorSize,
|
||||||
|
AutomaticCursorSizing,
|
||||||
|
DimLevel,
|
||||||
|
Display,
|
||||||
|
DisplayCityLocation,
|
||||||
|
DistanceSpacingEnabled,
|
||||||
|
EditorTip,
|
||||||
|
VideoEditor,
|
||||||
|
EditorDefaultSkin,
|
||||||
|
EditorSnakingSliders,
|
||||||
|
EditorHitAnimations,
|
||||||
|
EditorFollowPoints,
|
||||||
|
EditorStacking,
|
||||||
|
ForceSliderRendering,
|
||||||
|
FpsCounter,
|
||||||
|
FrameTimeDisplay,
|
||||||
|
GuideTips,
|
||||||
|
CursorRipple,
|
||||||
|
HighlightWords,
|
||||||
|
HighResolution,
|
||||||
|
HitLighting,
|
||||||
|
IgnoreBarline,
|
||||||
|
IgnoreBeatmapSamples,
|
||||||
|
IgnoreBeatmapSkins,
|
||||||
|
IgnoreList,
|
||||||
|
KeyOverlay,
|
||||||
|
Language,
|
||||||
|
LastPlayMode,
|
||||||
|
AllowNowPlayingHighlights,
|
||||||
|
LastVersion,
|
||||||
|
LastVersionPermissionsFailed,
|
||||||
|
LoadSubmittedThread,
|
||||||
|
LobbyPlayMode,
|
||||||
|
ShowInterface,
|
||||||
|
ShowInterfaceDuringRelax,
|
||||||
|
LobbyShowExistingOnly,
|
||||||
|
LobbyShowFriendsOnly,
|
||||||
|
LobbyShowFull,
|
||||||
|
LobbyShowInProgress,
|
||||||
|
LobbyShowPassworded,
|
||||||
|
LogPrivateMessages,
|
||||||
|
LowResolution,
|
||||||
|
ManiaSpeed,
|
||||||
|
UsePerBeatmapManiaSpeed,
|
||||||
|
ManiaSpeedBPMScale,
|
||||||
|
MenuTip,
|
||||||
|
MouseDisableButtons,
|
||||||
|
MouseDisableWheel,
|
||||||
|
MouseSpeed,
|
||||||
|
Offset,
|
||||||
|
ScoreMeterScale,
|
||||||
|
DistanceSpacing,
|
||||||
|
EditorBeatDivisor,
|
||||||
|
EditorGridSize,
|
||||||
|
EditorGridSizeDesign,
|
||||||
|
Height,
|
||||||
|
Width,
|
||||||
|
HeightFullscreen,
|
||||||
|
CustomFrameLimit,
|
||||||
|
WidthFullscreen,
|
||||||
|
MsnIntegration,
|
||||||
|
MyPcSucks,
|
||||||
|
NotifyFriends,
|
||||||
|
NotifySubmittedThread,
|
||||||
|
PopupDuringGameplay,
|
||||||
|
ProgressBarType,
|
||||||
|
RankType,
|
||||||
|
RefreshRate,
|
||||||
|
OverrideRefreshRate,
|
||||||
|
ScaleMode,
|
||||||
|
ScoreboardVisible,
|
||||||
|
ScoreMeter,
|
||||||
|
ScreenshotId,
|
||||||
|
MenuSnow,
|
||||||
|
MenuTriangles,
|
||||||
|
SongSelectThumbnails,
|
||||||
|
ScreenshotFormat,
|
||||||
|
ShowReplayComments,
|
||||||
|
ShowSpectators,
|
||||||
|
ShowStoryboard,
|
||||||
|
Skin,
|
||||||
|
SkinSamples,
|
||||||
|
SkipTablet,
|
||||||
|
SnakingSliders,
|
||||||
|
Tablet,
|
||||||
|
UpdatePending,
|
||||||
|
UserFilter,
|
||||||
|
UseSkinCursor,
|
||||||
|
UseTaikoSkin,
|
||||||
|
Video,
|
||||||
|
Wiimote,
|
||||||
|
YahooIntegration,
|
||||||
|
ForceFrameFlush,
|
||||||
|
DetectPerformanceIssues,
|
||||||
|
Fullscreen,
|
||||||
|
MenuMusic,
|
||||||
|
MenuVoice,
|
||||||
|
MenuParallax,
|
||||||
|
RawInput,
|
||||||
|
AbsoluteToOsuWindow,
|
||||||
|
ConfineMouse,
|
||||||
|
ShowMenuTips,
|
||||||
|
HiddenShowFirstApproach,
|
||||||
|
ComboColourSliderBall,
|
||||||
|
AlternativeChatFont,
|
||||||
|
Password,
|
||||||
|
Username,
|
||||||
|
DisplayStarsMaximum,
|
||||||
|
DisplayStarsMinimum,
|
||||||
|
AudioDevice,
|
||||||
|
ReleaseStream,
|
||||||
|
UpdateFailCount,
|
||||||
|
SavePassword,
|
||||||
|
SaveUsername,
|
||||||
|
TreeSortMode,
|
||||||
|
TreeSortMode2,
|
||||||
|
Letterboxing,
|
||||||
|
LetterboxPositionX,
|
||||||
|
LetterboxPositionY,
|
||||||
|
FrameSync,
|
||||||
|
ShowUnicode,
|
||||||
|
PermanentSongInfo,
|
||||||
|
Ticker,
|
||||||
|
CompatibilityContext,
|
||||||
|
CanForceOptimusCompatibility,
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -84,7 +84,7 @@ namespace osu.Game.GameModes.Menu
|
|||||||
Spacing = new Vector2(-wedge_width, 0),
|
Spacing = new Vector2(-wedge_width, 0),
|
||||||
Children = new[]
|
Children = new[]
|
||||||
{
|
{
|
||||||
settingsButton = new Button(@"settings", @"options", FontAwesome.gear, new Color4(85, 85, 85, 255), OnSettings, -wedge_width, Key.O),
|
settingsButton = new Button(@"settings", @"options", FontAwesome.gear, new Color4(85, 85, 85, 255), () => OnSettings?.Invoke(), -wedge_width, Key.O),
|
||||||
backButton = new Button(@"back", @"back", FontAwesome.fa_osu_left_o, new Color4(51, 58, 94, 255), onBack, -wedge_width, Key.Escape),
|
backButton = new Button(@"back", @"back", FontAwesome.fa_osu_left_o, new Color4(51, 58, 94, 255), onBack, -wedge_width, Key.Escape),
|
||||||
iconFacade = new Container //need a container to make the osu! icon flow properly.
|
iconFacade = new Container //need a container to make the osu! icon flow properly.
|
||||||
{
|
{
|
||||||
|
13
osu.Game/Graphics/UserInterface/LoadingAnimation.cs
Normal file
13
osu.Game/Graphics/UserInterface/LoadingAnimation.cs
Normal file
@ -0,0 +1,13 @@
|
|||||||
|
using System;
|
||||||
|
using osu.Framework.Graphics.Sprites;
|
||||||
|
|
||||||
|
namespace osu.Game.Graphics.UserInterface
|
||||||
|
{
|
||||||
|
public class LoadingAnimation : SpriteText
|
||||||
|
{
|
||||||
|
public LoadingAnimation()
|
||||||
|
{
|
||||||
|
Text = "Loading";
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
15
osu.Game/Graphics/UserInterface/OsuButton.cs
Normal file
15
osu.Game/Graphics/UserInterface/OsuButton.cs
Normal file
@ -0,0 +1,15 @@
|
|||||||
|
using System;
|
||||||
|
using OpenTK.Graphics;
|
||||||
|
using osu.Framework.Graphics.UserInterface;
|
||||||
|
|
||||||
|
namespace osu.Game.Graphics.UserInterface
|
||||||
|
{
|
||||||
|
public class OsuButton : Button
|
||||||
|
{
|
||||||
|
public OsuButton()
|
||||||
|
{
|
||||||
|
Height = 25;
|
||||||
|
Colour = new Color4(14, 132, 165, 255);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
@ -61,7 +61,7 @@ namespace osu.Game
|
|||||||
Schedule(delegate { Beatmaps.Import(args); });
|
Schedule(delegate { Beatmaps.Import(args); });
|
||||||
|
|
||||||
//attach our bindables to the audio subsystem.
|
//attach our bindables to the audio subsystem.
|
||||||
Audio.Volume.Weld(Config.GetBindable<double>(OsuConfig.VolumeGlobal));
|
Audio.Volume.Weld(Config.GetBindable<double>(OsuConfig.VolumeUniversal));
|
||||||
Audio.VolumeSample.Weld(Config.GetBindable<double>(OsuConfig.VolumeEffect));
|
Audio.VolumeSample.Weld(Config.GetBindable<double>(OsuConfig.VolumeEffect));
|
||||||
Audio.VolumeTrack.Weld(Config.GetBindable<double>(OsuConfig.VolumeMusic));
|
Audio.VolumeTrack.Weld(Config.GetBindable<double>(OsuConfig.VolumeMusic));
|
||||||
|
|
||||||
|
@ -7,6 +7,7 @@ using osu.Framework.Graphics.Containers;
|
|||||||
using osu.Framework.Graphics.Cursor;
|
using osu.Framework.Graphics.Cursor;
|
||||||
using osu.Framework.Graphics.Textures;
|
using osu.Framework.Graphics.Textures;
|
||||||
using osu.Framework.IO.Stores;
|
using osu.Framework.IO.Stores;
|
||||||
|
using osu.Framework.Platform;
|
||||||
using osu.Game.Beatmaps;
|
using osu.Game.Beatmaps;
|
||||||
using osu.Game.Beatmaps.IO;
|
using osu.Game.Beatmaps.IO;
|
||||||
using osu.Game.Configuration;
|
using osu.Game.Configuration;
|
||||||
@ -21,12 +22,12 @@ namespace osu.Game
|
|||||||
{
|
{
|
||||||
public class OsuGameBase : BaseGame
|
public class OsuGameBase : BaseGame
|
||||||
{
|
{
|
||||||
internal OsuConfigManager Config = new OsuConfigManager();
|
internal OsuConfigManager Config;
|
||||||
public BeatmapDatabase Beatmaps { get; private set; }
|
public BeatmapDatabase Beatmaps { get; private set; }
|
||||||
|
|
||||||
protected override string MainResourceFile => @"osu.Game.Resources.dll";
|
protected override string MainResourceFile => @"osu.Game.Resources.dll";
|
||||||
|
|
||||||
public Options Options;
|
public OptionsOverlay Options;
|
||||||
public APIAccess API;
|
public APIAccess API;
|
||||||
|
|
||||||
protected override Container Content => ratioContainer;
|
protected override Container Content => ratioContainer;
|
||||||
@ -43,7 +44,7 @@ namespace osu.Game
|
|||||||
|
|
||||||
Children = new Drawable[]
|
Children = new Drawable[]
|
||||||
{
|
{
|
||||||
Options = new Options(),
|
Options = new OptionsOverlay(),
|
||||||
Cursor = new OsuCursorContainer()
|
Cursor = new OsuCursorContainer()
|
||||||
};
|
};
|
||||||
|
|
||||||
@ -76,6 +77,13 @@ namespace osu.Game
|
|||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public override void SetHost(BasicGameHost host)
|
||||||
|
{
|
||||||
|
if (Config == null)
|
||||||
|
Config = new OsuConfigManager(host.Storage);
|
||||||
|
base.SetHost(host);
|
||||||
|
}
|
||||||
|
|
||||||
protected override void Update()
|
protected override void Update()
|
||||||
{
|
{
|
||||||
base.Update();
|
base.Update();
|
||||||
|
@ -1,62 +0,0 @@
|
|||||||
//Copyright (c) 2007-2016 ppy Pty Ltd <contact@ppy.sh>.
|
|
||||||
//Licensed under the MIT Licence - https://raw.githubusercontent.com/ppy/osu/master/LICENCE
|
|
||||||
|
|
||||||
using OpenTK;
|
|
||||||
using OpenTK.Graphics;
|
|
||||||
using OpenTK.Input;
|
|
||||||
using osu.Framework;
|
|
||||||
using osu.Framework.Graphics;
|
|
||||||
using osu.Framework.Graphics.Containers;
|
|
||||||
using osu.Framework.Graphics.Sprites;
|
|
||||||
using osu.Framework.Graphics.Transformations;
|
|
||||||
using osu.Framework.Input;
|
|
||||||
|
|
||||||
namespace osu.Game.Overlays
|
|
||||||
{
|
|
||||||
public class Options : OverlayContainer
|
|
||||||
{
|
|
||||||
private const float width = 300;
|
|
||||||
|
|
||||||
protected override void Load(BaseGame game)
|
|
||||||
{
|
|
||||||
base.Load(game);
|
|
||||||
|
|
||||||
Depth = float.MaxValue;
|
|
||||||
RelativeSizeAxes = Axes.Y;
|
|
||||||
Size = new Vector2(width, 1);
|
|
||||||
Position = new Vector2(-width, 0);
|
|
||||||
|
|
||||||
Children = new Drawable[]
|
|
||||||
{
|
|
||||||
new Box
|
|
||||||
{
|
|
||||||
RelativeSizeAxes = Axes.Both,
|
|
||||||
Colour = new Color4(0.1f, 0.1f, 0.1f, 0.9f)
|
|
||||||
}
|
|
||||||
};
|
|
||||||
}
|
|
||||||
|
|
||||||
protected override bool OnKeyDown(InputState state, KeyDownEventArgs args)
|
|
||||||
{
|
|
||||||
switch (args.Key)
|
|
||||||
{
|
|
||||||
case Key.Escape:
|
|
||||||
if (State == Visibility.Hidden) return false;
|
|
||||||
|
|
||||||
State = Visibility.Hidden;
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
return base.OnKeyDown(state, args);
|
|
||||||
}
|
|
||||||
|
|
||||||
protected override void PopIn()
|
|
||||||
{
|
|
||||||
MoveToX(0, 300, EasingTypes.Out);
|
|
||||||
}
|
|
||||||
|
|
||||||
protected override void PopOut()
|
|
||||||
{
|
|
||||||
MoveToX(-width, 300, EasingTypes.Out);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
30
osu.Game/Overlays/Options/AlertsPrivacyOptions.cs
Normal file
30
osu.Game/Overlays/Options/AlertsPrivacyOptions.cs
Normal file
@ -0,0 +1,30 @@
|
|||||||
|
using System;
|
||||||
|
using osu.Framework.Graphics;
|
||||||
|
using osu.Framework.Graphics.UserInterface;
|
||||||
|
|
||||||
|
namespace osu.Game.Overlays.Options
|
||||||
|
{
|
||||||
|
public class AlertsPrivacyOptions : OptionsSubsection
|
||||||
|
{
|
||||||
|
protected override string Header => "Alerts & Privacy";
|
||||||
|
|
||||||
|
public AlertsPrivacyOptions()
|
||||||
|
{
|
||||||
|
// TODO: this should probably be split into Alerts and Privacy
|
||||||
|
Children = new Drawable[]
|
||||||
|
{
|
||||||
|
new BasicCheckBox { LabelText = "Chat ticker" },
|
||||||
|
new BasicCheckBox { LabelText = "Automatically hide chat during gameplay" },
|
||||||
|
new BasicCheckBox { LabelText = "Show a notification popup when someone says your name" },
|
||||||
|
new BasicCheckBox { LabelText = "Show chat message notifications" },
|
||||||
|
new BasicCheckBox { LabelText = "Play a sound when someone says your name" },
|
||||||
|
new BasicCheckBox { LabelText = "Share your city location with others" },
|
||||||
|
new BasicCheckBox { LabelText = "Show spectators" },
|
||||||
|
new BasicCheckBox { LabelText = "Automatically link beatmaps to spectators" },
|
||||||
|
new BasicCheckBox { LabelText = "Show notification popups instantly during gameplay" },
|
||||||
|
new BasicCheckBox { LabelText = "Show notification popups when friends change status" },
|
||||||
|
new BasicCheckBox { LabelText = "Allow multiplayer game invites from all users" },
|
||||||
|
};
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
18
osu.Game/Overlays/Options/AudioDevicesOptions.cs
Normal file
18
osu.Game/Overlays/Options/AudioDevicesOptions.cs
Normal file
@ -0,0 +1,18 @@
|
|||||||
|
using System;
|
||||||
|
using osu.Framework.Graphics.Sprites;
|
||||||
|
|
||||||
|
namespace osu.Game.Overlays.Options
|
||||||
|
{
|
||||||
|
public class AudioDevicesOptions : OptionsSubsection
|
||||||
|
{
|
||||||
|
protected override string Header => "Devices";
|
||||||
|
|
||||||
|
public AudioDevicesOptions()
|
||||||
|
{
|
||||||
|
Children = new[]
|
||||||
|
{
|
||||||
|
new SpriteText { Text = "Output device: TODO dropdown" }
|
||||||
|
};
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
20
osu.Game/Overlays/Options/AudioOptions.cs
Normal file
20
osu.Game/Overlays/Options/AudioOptions.cs
Normal file
@ -0,0 +1,20 @@
|
|||||||
|
using System;
|
||||||
|
using osu.Framework.Graphics;
|
||||||
|
|
||||||
|
namespace osu.Game.Overlays.Options
|
||||||
|
{
|
||||||
|
public class AudioOptions : OptionsSection
|
||||||
|
{
|
||||||
|
protected override string Header => "Audio";
|
||||||
|
|
||||||
|
public AudioOptions()
|
||||||
|
{
|
||||||
|
Children = new Drawable[]
|
||||||
|
{
|
||||||
|
new AudioDevicesOptions(),
|
||||||
|
new VolumeOptions(),
|
||||||
|
new OffsetAdjustmentOptions(),
|
||||||
|
};
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
27
osu.Game/Overlays/Options/DetailOptions.cs
Normal file
27
osu.Game/Overlays/Options/DetailOptions.cs
Normal file
@ -0,0 +1,27 @@
|
|||||||
|
using System;
|
||||||
|
using osu.Framework.Graphics;
|
||||||
|
using osu.Framework.Graphics.Sprites;
|
||||||
|
using osu.Framework.Graphics.UserInterface;
|
||||||
|
|
||||||
|
namespace osu.Game.Overlays.Options
|
||||||
|
{
|
||||||
|
public class DetailOptions : OptionsSubsection
|
||||||
|
{
|
||||||
|
protected override string Header => "Detail Settings";
|
||||||
|
|
||||||
|
public DetailOptions()
|
||||||
|
{
|
||||||
|
Children = new Drawable[]
|
||||||
|
{
|
||||||
|
new BasicCheckBox { LabelText = "Snaking sliders" },
|
||||||
|
new BasicCheckBox { LabelText = "Background video" },
|
||||||
|
new BasicCheckBox { LabelText = "Storyboards" },
|
||||||
|
new BasicCheckBox { LabelText = "Combo bursts" },
|
||||||
|
new BasicCheckBox { LabelText = "Hit lighting" },
|
||||||
|
new BasicCheckBox { LabelText = "Shaders" },
|
||||||
|
new BasicCheckBox { LabelText = "Softening filter" },
|
||||||
|
new SpriteText { Text = "Screenshot format TODO: dropdown" }
|
||||||
|
};
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
27
osu.Game/Overlays/Options/EditorOptions.cs
Normal file
27
osu.Game/Overlays/Options/EditorOptions.cs
Normal file
@ -0,0 +1,27 @@
|
|||||||
|
using System;
|
||||||
|
using OpenTK;
|
||||||
|
using osu.Framework.Graphics;
|
||||||
|
using osu.Framework.Graphics.UserInterface;
|
||||||
|
|
||||||
|
namespace osu.Game.Overlays.Options
|
||||||
|
{
|
||||||
|
public class EditorOptions : OptionsSection
|
||||||
|
{
|
||||||
|
protected override string Header => "Editor";
|
||||||
|
|
||||||
|
public EditorOptions()
|
||||||
|
{
|
||||||
|
content.Spacing = new Vector2(0, 5);
|
||||||
|
Children = new Drawable[]
|
||||||
|
{
|
||||||
|
new BasicCheckBox { LabelText = "Background video" },
|
||||||
|
new BasicCheckBox { LabelText = "Always use default skin" },
|
||||||
|
new BasicCheckBox { LabelText = "Snaking sliders" },
|
||||||
|
new BasicCheckBox { LabelText = "Hit animations" },
|
||||||
|
new BasicCheckBox { LabelText = "Follow points" },
|
||||||
|
new BasicCheckBox { LabelText = "Stacking" },
|
||||||
|
};
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
19
osu.Game/Overlays/Options/GameplayOptions.cs
Normal file
19
osu.Game/Overlays/Options/GameplayOptions.cs
Normal file
@ -0,0 +1,19 @@
|
|||||||
|
using System;
|
||||||
|
using osu.Framework.Graphics;
|
||||||
|
|
||||||
|
namespace osu.Game.Overlays.Options
|
||||||
|
{
|
||||||
|
public class GameplayOptions : OptionsSection
|
||||||
|
{
|
||||||
|
protected override string Header => "Gameplay";
|
||||||
|
|
||||||
|
public GameplayOptions()
|
||||||
|
{
|
||||||
|
Children = new Drawable[]
|
||||||
|
{
|
||||||
|
new GeneralGameplayOptions(),
|
||||||
|
new SongSelectGameplayOptions(),
|
||||||
|
};
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
27
osu.Game/Overlays/Options/GeneralGameplayOptions.cs
Normal file
27
osu.Game/Overlays/Options/GeneralGameplayOptions.cs
Normal file
@ -0,0 +1,27 @@
|
|||||||
|
using System;
|
||||||
|
using osu.Framework.Graphics;
|
||||||
|
using osu.Framework.Graphics.Sprites;
|
||||||
|
using osu.Framework.Graphics.UserInterface;
|
||||||
|
|
||||||
|
namespace osu.Game.Overlays.Options
|
||||||
|
{
|
||||||
|
public class GeneralGameplayOptions : OptionsSubsection
|
||||||
|
{
|
||||||
|
protected override string Header => "General";
|
||||||
|
|
||||||
|
public GeneralGameplayOptions()
|
||||||
|
{
|
||||||
|
Children = new Drawable[]
|
||||||
|
{
|
||||||
|
new SpriteText { Text = "Background dim: TODO slider" },
|
||||||
|
new SpriteText { Text = "Progress display: TODO dropdown" },
|
||||||
|
new SpriteText { Text = "Score meter type: TODO dropdown" },
|
||||||
|
new SpriteText { Text = "Score meter size: TODO slider" },
|
||||||
|
new BasicCheckBox { LabelText = "Always show key overlay" },
|
||||||
|
new BasicCheckBox { LabelText = "Show approach circle on first \"Hidden\" object" },
|
||||||
|
new BasicCheckBox { LabelText = "Scale osu!mania scroll speed with BPM" },
|
||||||
|
new BasicCheckBox { LabelText = "Remember osu!mania scroll speed per beatmap" },
|
||||||
|
};
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
26
osu.Game/Overlays/Options/GeneralOptions.cs
Normal file
26
osu.Game/Overlays/Options/GeneralOptions.cs
Normal file
@ -0,0 +1,26 @@
|
|||||||
|
using System;
|
||||||
|
using OpenTK.Graphics;
|
||||||
|
using osu.Framework.Graphics;
|
||||||
|
using osu.Framework.Graphics.Sprites;
|
||||||
|
using osu.Framework.Graphics.UserInterface;
|
||||||
|
using osu.Framework.Platform;
|
||||||
|
using osu.Game.Online.API;
|
||||||
|
|
||||||
|
namespace osu.Game.Overlays.Options
|
||||||
|
{
|
||||||
|
public class GeneralOptions : OptionsSection
|
||||||
|
{
|
||||||
|
protected override string Header => "General";
|
||||||
|
|
||||||
|
public GeneralOptions()
|
||||||
|
{
|
||||||
|
Children = new Drawable[]
|
||||||
|
{
|
||||||
|
new LoginOptions(),
|
||||||
|
new LanguageOptions(),
|
||||||
|
new UpdateOptions(),
|
||||||
|
};
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
23
osu.Game/Overlays/Options/GraphicsOptions.cs
Normal file
23
osu.Game/Overlays/Options/GraphicsOptions.cs
Normal file
@ -0,0 +1,23 @@
|
|||||||
|
using System;
|
||||||
|
using osu.Framework.Graphics;
|
||||||
|
|
||||||
|
namespace osu.Game.Overlays.Options
|
||||||
|
{
|
||||||
|
public class GraphicsOptions : OptionsSection
|
||||||
|
{
|
||||||
|
protected override string Header => "Graphics";
|
||||||
|
|
||||||
|
public GraphicsOptions()
|
||||||
|
{
|
||||||
|
Children = new Drawable[]
|
||||||
|
{
|
||||||
|
new RendererOptions(),
|
||||||
|
new LayoutOptions(),
|
||||||
|
new DetailOptions(),
|
||||||
|
new MainMenuOptions(),
|
||||||
|
new SongSelectGraphicsOptions(),
|
||||||
|
};
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
27
osu.Game/Overlays/Options/InGameChatOptions.cs
Normal file
27
osu.Game/Overlays/Options/InGameChatOptions.cs
Normal file
@ -0,0 +1,27 @@
|
|||||||
|
using System;
|
||||||
|
using osu.Framework.Graphics;
|
||||||
|
using osu.Framework.Graphics.Sprites;
|
||||||
|
using osu.Framework.Graphics.UserInterface;
|
||||||
|
|
||||||
|
namespace osu.Game.Overlays.Options
|
||||||
|
{
|
||||||
|
public class InGameChatOptions : OptionsSubsection
|
||||||
|
{
|
||||||
|
protected override string Header => "In-game Chat";
|
||||||
|
|
||||||
|
public InGameChatOptions()
|
||||||
|
{
|
||||||
|
Children = new Drawable[]
|
||||||
|
{
|
||||||
|
new BasicCheckBox { LabelText = "Filter offensive words" },
|
||||||
|
new BasicCheckBox { LabelText = "Filter foreign characters" },
|
||||||
|
new BasicCheckBox { LabelText = "Log private messages" },
|
||||||
|
new BasicCheckBox { LabelText = "Block private messages from non-friends" },
|
||||||
|
new SpriteText { Text = "Chat ignore list (space-seperated list)" },
|
||||||
|
new TextBox { Height = 20, RelativeSizeAxes = Axes.X },
|
||||||
|
new SpriteText { Text = "Chat highlight words (space-seperated list)" },
|
||||||
|
new TextBox { Height = 20, RelativeSizeAxes = Axes.X },
|
||||||
|
};
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
21
osu.Game/Overlays/Options/InputOptions.cs
Normal file
21
osu.Game/Overlays/Options/InputOptions.cs
Normal file
@ -0,0 +1,21 @@
|
|||||||
|
using System;
|
||||||
|
using osu.Framework.Graphics;
|
||||||
|
|
||||||
|
namespace osu.Game.Overlays.Options
|
||||||
|
{
|
||||||
|
public class InputOptions : OptionsSection
|
||||||
|
{
|
||||||
|
protected override string Header => "Input";
|
||||||
|
|
||||||
|
public InputOptions()
|
||||||
|
{
|
||||||
|
Children = new Drawable[]
|
||||||
|
{
|
||||||
|
new MouseOptions(),
|
||||||
|
new KeyboardOptions(),
|
||||||
|
new OtherInputOptions(),
|
||||||
|
};
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
28
osu.Game/Overlays/Options/KeyboardOptions.cs
Normal file
28
osu.Game/Overlays/Options/KeyboardOptions.cs
Normal file
@ -0,0 +1,28 @@
|
|||||||
|
using System;
|
||||||
|
using osu.Framework.Graphics;
|
||||||
|
using osu.Game.Graphics.UserInterface;
|
||||||
|
|
||||||
|
namespace osu.Game.Overlays.Options
|
||||||
|
{
|
||||||
|
public class KeyboardOptions : OptionsSubsection
|
||||||
|
{
|
||||||
|
protected override string Header => "Keyboard";
|
||||||
|
|
||||||
|
public KeyboardOptions()
|
||||||
|
{
|
||||||
|
Children = new Drawable[]
|
||||||
|
{
|
||||||
|
new OsuButton
|
||||||
|
{
|
||||||
|
RelativeSizeAxes = Axes.X,
|
||||||
|
Text = "Change keyboard bindings"
|
||||||
|
},
|
||||||
|
new OsuButton
|
||||||
|
{
|
||||||
|
RelativeSizeAxes = Axes.X,
|
||||||
|
Text = "osu!mania layout"
|
||||||
|
}
|
||||||
|
};
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
22
osu.Game/Overlays/Options/LanguageOptions.cs
Normal file
22
osu.Game/Overlays/Options/LanguageOptions.cs
Normal file
@ -0,0 +1,22 @@
|
|||||||
|
using System;
|
||||||
|
using osu.Framework.Graphics;
|
||||||
|
using osu.Framework.Graphics.Sprites;
|
||||||
|
using osu.Framework.Graphics.UserInterface;
|
||||||
|
|
||||||
|
namespace osu.Game.Overlays.Options
|
||||||
|
{
|
||||||
|
public class LanguageOptions : OptionsSubsection
|
||||||
|
{
|
||||||
|
protected override string Header => "Language";
|
||||||
|
|
||||||
|
public LanguageOptions()
|
||||||
|
{
|
||||||
|
Children = new Drawable[]
|
||||||
|
{
|
||||||
|
new SpriteText { Text = "TODO: Dropdown" },
|
||||||
|
new BasicCheckBox { LabelText = "Prefer metadata in original language" },
|
||||||
|
new BasicCheckBox { LabelText = "Use alternative font for chat display" },
|
||||||
|
};
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
26
osu.Game/Overlays/Options/LayoutOptions.cs
Normal file
26
osu.Game/Overlays/Options/LayoutOptions.cs
Normal file
@ -0,0 +1,26 @@
|
|||||||
|
using System;
|
||||||
|
using osu.Framework.Graphics;
|
||||||
|
using osu.Framework.Graphics.Sprites;
|
||||||
|
using osu.Framework.Graphics.UserInterface;
|
||||||
|
|
||||||
|
namespace osu.Game.Overlays.Options
|
||||||
|
{
|
||||||
|
public class LayoutOptions : OptionsSubsection
|
||||||
|
{
|
||||||
|
protected override string Header => "Layout";
|
||||||
|
|
||||||
|
public LayoutOptions()
|
||||||
|
{
|
||||||
|
Children = new Drawable[]
|
||||||
|
{
|
||||||
|
new SpriteText { Text = "Resolution: TODO dropdown" },
|
||||||
|
new BasicCheckBox { LabelText = "Fullscreen mode" },
|
||||||
|
new BasicCheckBox { LabelText = "Letterboxing" },
|
||||||
|
new SpriteText { Text = "Horizontal position" },
|
||||||
|
new SpriteText { Text = "TODO: slider" },
|
||||||
|
new SpriteText { Text = "Vertical position" },
|
||||||
|
new SpriteText { Text = "TODO: slider" },
|
||||||
|
};
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
68
osu.Game/Overlays/Options/LoginOptions.cs
Normal file
68
osu.Game/Overlays/Options/LoginOptions.cs
Normal file
@ -0,0 +1,68 @@
|
|||||||
|
using System;
|
||||||
|
using OpenTK;
|
||||||
|
using OpenTK.Graphics;
|
||||||
|
using osu.Framework;
|
||||||
|
using osu.Framework.Graphics;
|
||||||
|
using osu.Framework.Graphics.Containers;
|
||||||
|
using osu.Framework.Graphics.Sprites;
|
||||||
|
using osu.Framework.Graphics.UserInterface;
|
||||||
|
using osu.Game.Graphics.UserInterface;
|
||||||
|
using osu.Game.Online.API;
|
||||||
|
|
||||||
|
namespace osu.Game.Overlays.Options
|
||||||
|
{
|
||||||
|
public class LoginOptions : OptionsSubsection
|
||||||
|
{
|
||||||
|
private Container loginForm;
|
||||||
|
protected override string Header => "Sign In";
|
||||||
|
|
||||||
|
public LoginOptions()
|
||||||
|
{
|
||||||
|
Children = new[]
|
||||||
|
{
|
||||||
|
loginForm = new Container
|
||||||
|
{
|
||||||
|
RelativeSizeAxes = Axes.X,
|
||||||
|
AutoSizeAxes = Axes.Y,
|
||||||
|
Children = new[] { new LoadingAnimation() }
|
||||||
|
}
|
||||||
|
};
|
||||||
|
}
|
||||||
|
|
||||||
|
protected override void Load(BaseGame game)
|
||||||
|
{
|
||||||
|
base.Load(game);
|
||||||
|
var osuGame = game as OsuGameBase;
|
||||||
|
if (osuGame == null)
|
||||||
|
return;
|
||||||
|
loginForm.Children = new Drawable[]
|
||||||
|
{
|
||||||
|
new LoginForm(osuGame.API)
|
||||||
|
};
|
||||||
|
}
|
||||||
|
|
||||||
|
class LoginForm : FlowContainer
|
||||||
|
{
|
||||||
|
public LoginForm(APIAccess api)
|
||||||
|
{
|
||||||
|
Direction = FlowDirection.VerticalOnly;
|
||||||
|
AutoSizeAxes = Axes.Y;
|
||||||
|
RelativeSizeAxes = Axes.X;
|
||||||
|
Spacing = new Vector2(0, 5);
|
||||||
|
// TODO: Wire things up
|
||||||
|
Children = new Drawable[]
|
||||||
|
{
|
||||||
|
new SpriteText { Text = "Username" },
|
||||||
|
new TextBox { Height = 20, RelativeSizeAxes = Axes.X, Text = api?.Username ?? string.Empty },
|
||||||
|
new SpriteText { Text = "Password" },
|
||||||
|
new TextBox { Height = 20, RelativeSizeAxes = Axes.X },
|
||||||
|
new OsuButton
|
||||||
|
{
|
||||||
|
RelativeSizeAxes = Axes.X,
|
||||||
|
Text = "Log in",
|
||||||
|
}
|
||||||
|
};
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
22
osu.Game/Overlays/Options/MainMenuOptions.cs
Normal file
22
osu.Game/Overlays/Options/MainMenuOptions.cs
Normal file
@ -0,0 +1,22 @@
|
|||||||
|
using System;
|
||||||
|
using osu.Framework.Graphics.UserInterface;
|
||||||
|
|
||||||
|
namespace osu.Game.Overlays.Options
|
||||||
|
{
|
||||||
|
public class MainMenuOptions : OptionsSubsection
|
||||||
|
{
|
||||||
|
protected override string Header => "Main Menu";
|
||||||
|
|
||||||
|
public MainMenuOptions()
|
||||||
|
{
|
||||||
|
Children = new[]
|
||||||
|
{
|
||||||
|
new BasicCheckBox { LabelText = "Snow" },
|
||||||
|
new BasicCheckBox { LabelText = "Parallax" },
|
||||||
|
new BasicCheckBox { LabelText = "Menu tips" },
|
||||||
|
new BasicCheckBox { LabelText = "Interface voices" },
|
||||||
|
new BasicCheckBox { LabelText = "osu! music theme" },
|
||||||
|
};
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
47
osu.Game/Overlays/Options/MaintenanceOptions.cs
Normal file
47
osu.Game/Overlays/Options/MaintenanceOptions.cs
Normal file
@ -0,0 +1,47 @@
|
|||||||
|
using System;
|
||||||
|
using OpenTK;
|
||||||
|
using osu.Framework.Graphics;
|
||||||
|
using osu.Framework.Graphics.Sprites;
|
||||||
|
using osu.Game.Graphics.UserInterface;
|
||||||
|
|
||||||
|
namespace osu.Game.Overlays.Options
|
||||||
|
{
|
||||||
|
public class MaintenanceOptions : OptionsSection
|
||||||
|
{
|
||||||
|
protected override string Header => "Maintenance";
|
||||||
|
|
||||||
|
public MaintenanceOptions()
|
||||||
|
{
|
||||||
|
content.Spacing = new Vector2(0, 5);
|
||||||
|
Children = new Drawable[]
|
||||||
|
{
|
||||||
|
new OsuButton
|
||||||
|
{
|
||||||
|
RelativeSizeAxes = Axes.X,
|
||||||
|
Text = "Delete all unranked maps",
|
||||||
|
},
|
||||||
|
new OsuButton
|
||||||
|
{
|
||||||
|
RelativeSizeAxes = Axes.X,
|
||||||
|
Text = "Repair folder permissions",
|
||||||
|
},
|
||||||
|
new OsuButton
|
||||||
|
{
|
||||||
|
RelativeSizeAxes = Axes.X,
|
||||||
|
Text = "Mark all maps as played",
|
||||||
|
},
|
||||||
|
new OsuButton
|
||||||
|
{
|
||||||
|
RelativeSizeAxes = Axes.X,
|
||||||
|
Text = "Run osu! updater",
|
||||||
|
},
|
||||||
|
new SpriteText
|
||||||
|
{
|
||||||
|
Text = "TODO: osu version here",
|
||||||
|
Anchor = Anchor.TopCentre,
|
||||||
|
Origin = Anchor.TopCentre,
|
||||||
|
},
|
||||||
|
};
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
26
osu.Game/Overlays/Options/MouseOptions.cs
Normal file
26
osu.Game/Overlays/Options/MouseOptions.cs
Normal file
@ -0,0 +1,26 @@
|
|||||||
|
using System;
|
||||||
|
using osu.Framework.Graphics;
|
||||||
|
using osu.Framework.Graphics.Sprites;
|
||||||
|
using osu.Framework.Graphics.UserInterface;
|
||||||
|
|
||||||
|
namespace osu.Game.Overlays.Options
|
||||||
|
{
|
||||||
|
public class MouseOptions : OptionsSubsection
|
||||||
|
{
|
||||||
|
protected override string Header => "Mouse";
|
||||||
|
|
||||||
|
public MouseOptions()
|
||||||
|
{
|
||||||
|
Children = new Drawable[]
|
||||||
|
{
|
||||||
|
new SpriteText { Text = "Sensitivity: TODO slider" },
|
||||||
|
new BasicCheckBox { LabelText = "Raw input" },
|
||||||
|
new BasicCheckBox { LabelText = "Map absolute raw input to the osu! window" },
|
||||||
|
new SpriteText { Text = "Confine mouse cursor: TODO dropdown" },
|
||||||
|
new BasicCheckBox { LabelText = "Disable mouse wheel in play mode" },
|
||||||
|
new BasicCheckBox { LabelText = "Disable mouse buttons in play mode" },
|
||||||
|
new BasicCheckBox { LabelText = "Cursor ripples" },
|
||||||
|
};
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
25
osu.Game/Overlays/Options/OffsetAdjustmentOptions.cs
Normal file
25
osu.Game/Overlays/Options/OffsetAdjustmentOptions.cs
Normal file
@ -0,0 +1,25 @@
|
|||||||
|
using System;
|
||||||
|
using osu.Framework.Graphics;
|
||||||
|
using osu.Framework.Graphics.Sprites;
|
||||||
|
using osu.Game.Graphics.UserInterface;
|
||||||
|
|
||||||
|
namespace osu.Game.Overlays.Options
|
||||||
|
{
|
||||||
|
public class OffsetAdjustmentOptions : OptionsSubsection
|
||||||
|
{
|
||||||
|
protected override string Header => "Offset Adjustment";
|
||||||
|
|
||||||
|
public OffsetAdjustmentOptions()
|
||||||
|
{
|
||||||
|
Children = new Drawable[]
|
||||||
|
{
|
||||||
|
new SpriteText { Text = "Universal Offset: TODO slider" },
|
||||||
|
new OsuButton
|
||||||
|
{
|
||||||
|
RelativeSizeAxes = Axes.X,
|
||||||
|
Text = "Offset wizard"
|
||||||
|
}
|
||||||
|
};
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
22
osu.Game/Overlays/Options/OnlineIntegrationOptions.cs
Normal file
22
osu.Game/Overlays/Options/OnlineIntegrationOptions.cs
Normal file
@ -0,0 +1,22 @@
|
|||||||
|
using System;
|
||||||
|
using osu.Framework.Graphics;
|
||||||
|
using osu.Framework.Graphics.UserInterface;
|
||||||
|
|
||||||
|
namespace osu.Game.Overlays.Options
|
||||||
|
{
|
||||||
|
public class OnlineIntegrationOptions : OptionsSubsection
|
||||||
|
{
|
||||||
|
protected override string Header => "Integration";
|
||||||
|
|
||||||
|
public OnlineIntegrationOptions()
|
||||||
|
{
|
||||||
|
Children = new Drawable[]
|
||||||
|
{
|
||||||
|
new BasicCheckBox { LabelText = "Integrate with Yahoo! status display" },
|
||||||
|
new BasicCheckBox { LabelText = "Integrate with MSN Live status display" },
|
||||||
|
new BasicCheckBox { LabelText = "Automatically start osu!direct downloads" },
|
||||||
|
new BasicCheckBox { LabelText = "Prefer no-video downloads" },
|
||||||
|
};
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
20
osu.Game/Overlays/Options/OnlineOptions.cs
Normal file
20
osu.Game/Overlays/Options/OnlineOptions.cs
Normal file
@ -0,0 +1,20 @@
|
|||||||
|
using System;
|
||||||
|
using osu.Framework.Graphics;
|
||||||
|
|
||||||
|
namespace osu.Game.Overlays.Options
|
||||||
|
{
|
||||||
|
public class OnlineOptions : OptionsSection
|
||||||
|
{
|
||||||
|
protected override string Header => "Online";
|
||||||
|
|
||||||
|
public OnlineOptions()
|
||||||
|
{
|
||||||
|
Children = new Drawable[]
|
||||||
|
{
|
||||||
|
new AlertsPrivacyOptions(),
|
||||||
|
new OnlineIntegrationOptions(),
|
||||||
|
new InGameChatOptions(),
|
||||||
|
};
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
64
osu.Game/Overlays/Options/OptionsSection.cs
Normal file
64
osu.Game/Overlays/Options/OptionsSection.cs
Normal file
@ -0,0 +1,64 @@
|
|||||||
|
using System;
|
||||||
|
using OpenTK;
|
||||||
|
using OpenTK.Graphics;
|
||||||
|
using osu.Framework.Graphics;
|
||||||
|
using osu.Framework.Graphics.Containers;
|
||||||
|
using osu.Framework.Graphics.Primitives;
|
||||||
|
using osu.Framework.Graphics.Sprites;
|
||||||
|
|
||||||
|
namespace osu.Game.Overlays.Options
|
||||||
|
{
|
||||||
|
public abstract class OptionsSection : Container
|
||||||
|
{
|
||||||
|
protected FlowContainer content;
|
||||||
|
protected override Container Content => content;
|
||||||
|
|
||||||
|
protected abstract string Header { get; }
|
||||||
|
|
||||||
|
public OptionsSection()
|
||||||
|
{
|
||||||
|
const int headerSize = 30, headerMargin = 25;
|
||||||
|
const int borderSize = 2;
|
||||||
|
AutoSizeAxes = Axes.Y;
|
||||||
|
RelativeSizeAxes = Axes.X;
|
||||||
|
AddInternal(new Drawable[]
|
||||||
|
{
|
||||||
|
new Box
|
||||||
|
{
|
||||||
|
Colour = new Color4(3, 3, 3, 255),
|
||||||
|
RelativeSizeAxes = Axes.X,
|
||||||
|
Height = borderSize,
|
||||||
|
},
|
||||||
|
new Container
|
||||||
|
{
|
||||||
|
Padding = new MarginPadding
|
||||||
|
{
|
||||||
|
Top = 10 + borderSize,
|
||||||
|
Left = OptionsOverlay.SideMargins,
|
||||||
|
Right = OptionsOverlay.SideMargins,
|
||||||
|
Bottom = 10,
|
||||||
|
},
|
||||||
|
RelativeSizeAxes = Axes.X,
|
||||||
|
AutoSizeAxes = Axes.Y,
|
||||||
|
Children = new[]
|
||||||
|
{
|
||||||
|
new SpriteText
|
||||||
|
{
|
||||||
|
TextSize = headerSize,
|
||||||
|
Colour = new Color4(247, 198, 35, 255),
|
||||||
|
Text = Header,
|
||||||
|
},
|
||||||
|
content = new FlowContainer
|
||||||
|
{
|
||||||
|
Margin = new MarginPadding { Top = headerSize + headerMargin },
|
||||||
|
Direction = FlowDirection.VerticalOnly,
|
||||||
|
Spacing = new Vector2(0, 25),
|
||||||
|
AutoSizeAxes = Axes.Y,
|
||||||
|
RelativeSizeAxes = Axes.X,
|
||||||
|
},
|
||||||
|
}
|
||||||
|
},
|
||||||
|
});
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
42
osu.Game/Overlays/Options/OptionsSubsection.cs
Normal file
42
osu.Game/Overlays/Options/OptionsSubsection.cs
Normal file
@ -0,0 +1,42 @@
|
|||||||
|
using System;
|
||||||
|
using OpenTK;
|
||||||
|
using osu.Framework.Graphics;
|
||||||
|
using osu.Framework.Graphics.Containers;
|
||||||
|
using osu.Framework.Graphics.Sprites;
|
||||||
|
|
||||||
|
namespace osu.Game.Overlays.Options
|
||||||
|
{
|
||||||
|
public abstract class OptionsSubsection : Container
|
||||||
|
{
|
||||||
|
private Container content;
|
||||||
|
protected override Container Content => content;
|
||||||
|
|
||||||
|
protected abstract string Header { get; }
|
||||||
|
|
||||||
|
public OptionsSubsection()
|
||||||
|
{
|
||||||
|
RelativeSizeAxes = Axes.X;
|
||||||
|
AutoSizeAxes = Axes.Y;
|
||||||
|
AddInternal(new Drawable[]
|
||||||
|
{
|
||||||
|
content = new FlowContainer
|
||||||
|
{
|
||||||
|
Direction = FlowDirection.VerticalOnly,
|
||||||
|
RelativeSizeAxes = Axes.X,
|
||||||
|
AutoSizeAxes = Axes.Y,
|
||||||
|
Spacing = new Vector2(0, 5),
|
||||||
|
Children = new[]
|
||||||
|
{
|
||||||
|
new SpriteText
|
||||||
|
{
|
||||||
|
TextSize = 25,
|
||||||
|
Text = Header,
|
||||||
|
// TODO: Bold
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
});
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
21
osu.Game/Overlays/Options/OtherInputOptions.cs
Normal file
21
osu.Game/Overlays/Options/OtherInputOptions.cs
Normal file
@ -0,0 +1,21 @@
|
|||||||
|
using System;
|
||||||
|
using osu.Framework.Graphics;
|
||||||
|
using osu.Framework.Graphics.UserInterface;
|
||||||
|
|
||||||
|
namespace osu.Game.Overlays.Options
|
||||||
|
{
|
||||||
|
public class OtherInputOptions : OptionsSubsection
|
||||||
|
{
|
||||||
|
protected override string Header => "Other";
|
||||||
|
|
||||||
|
public OtherInputOptions()
|
||||||
|
{
|
||||||
|
Children = new Drawable[]
|
||||||
|
{
|
||||||
|
new BasicCheckBox { LabelText = "OS TabletPC support" },
|
||||||
|
new BasicCheckBox { LabelText = "Wiimote/TaTaCon Drum Support" },
|
||||||
|
};
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
24
osu.Game/Overlays/Options/RendererOptions.cs
Normal file
24
osu.Game/Overlays/Options/RendererOptions.cs
Normal file
@ -0,0 +1,24 @@
|
|||||||
|
using System;
|
||||||
|
using osu.Framework.Graphics;
|
||||||
|
using osu.Framework.Graphics.Sprites;
|
||||||
|
using osu.Framework.Graphics.UserInterface;
|
||||||
|
|
||||||
|
namespace osu.Game.Overlays.Options
|
||||||
|
{
|
||||||
|
public class RendererOptions : OptionsSubsection
|
||||||
|
{
|
||||||
|
protected override string Header => "Renderer";
|
||||||
|
|
||||||
|
public RendererOptions()
|
||||||
|
{
|
||||||
|
// NOTE: Compatability mode omitted
|
||||||
|
Children = new Drawable[]
|
||||||
|
{
|
||||||
|
new SpriteText { Text = "Frame limiter: TODO dropdown" },
|
||||||
|
new BasicCheckBox { LabelText = "Show FPS counter" },
|
||||||
|
new BasicCheckBox { LabelText = "Reduce dropped frames" },
|
||||||
|
new BasicCheckBox { LabelText = "Detect performance issues" },
|
||||||
|
};
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
45
osu.Game/Overlays/Options/SkinOptions.cs
Normal file
45
osu.Game/Overlays/Options/SkinOptions.cs
Normal file
@ -0,0 +1,45 @@
|
|||||||
|
using System;
|
||||||
|
using OpenTK;
|
||||||
|
using osu.Framework.Graphics;
|
||||||
|
using osu.Framework.Graphics.Sprites;
|
||||||
|
using osu.Framework.Graphics.UserInterface;
|
||||||
|
using osu.Game.Graphics.UserInterface;
|
||||||
|
|
||||||
|
namespace osu.Game.Overlays.Options
|
||||||
|
{
|
||||||
|
public class SkinOptions : OptionsSection
|
||||||
|
{
|
||||||
|
protected override string Header => "Skin";
|
||||||
|
|
||||||
|
public SkinOptions()
|
||||||
|
{
|
||||||
|
content.Spacing = new Vector2(0, 5);
|
||||||
|
Children = new Drawable[]
|
||||||
|
{
|
||||||
|
new SpriteText { Text = "TODO: Skin preview textures" },
|
||||||
|
new SpriteText { Text = "Current skin: TODO dropdown" },
|
||||||
|
new OsuButton
|
||||||
|
{
|
||||||
|
RelativeSizeAxes = Axes.X,
|
||||||
|
Text = "Preview gameplay",
|
||||||
|
},
|
||||||
|
new OsuButton
|
||||||
|
{
|
||||||
|
RelativeSizeAxes = Axes.X,
|
||||||
|
Text = "Open skin folder",
|
||||||
|
},
|
||||||
|
new OsuButton
|
||||||
|
{
|
||||||
|
RelativeSizeAxes = Axes.X,
|
||||||
|
Text = "Export as .osk",
|
||||||
|
},
|
||||||
|
new BasicCheckBox { LabelText = "Ignore all beatmap skins" },
|
||||||
|
new BasicCheckBox { LabelText = "Use skin's sound samples" },
|
||||||
|
new BasicCheckBox { LabelText = "Use Taiko skin for Taiko mode" },
|
||||||
|
new BasicCheckBox { LabelText = "Always use skin cursor" },
|
||||||
|
new SpriteText { Text = "Cursor size: TODO slider" },
|
||||||
|
new BasicCheckBox { LabelText = "Automatic cursor size" },
|
||||||
|
};
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
21
osu.Game/Overlays/Options/SongSelectGameplayOptions.cs
Normal file
21
osu.Game/Overlays/Options/SongSelectGameplayOptions.cs
Normal file
@ -0,0 +1,21 @@
|
|||||||
|
using System;
|
||||||
|
using osu.Framework.Graphics;
|
||||||
|
using osu.Framework.Graphics.Sprites;
|
||||||
|
|
||||||
|
namespace osu.Game.Overlays.Options
|
||||||
|
{
|
||||||
|
public class SongSelectGameplayOptions : OptionsSubsection
|
||||||
|
{
|
||||||
|
protected override string Header => "Song Select";
|
||||||
|
|
||||||
|
public SongSelectGameplayOptions()
|
||||||
|
{
|
||||||
|
Children = new Drawable[]
|
||||||
|
{
|
||||||
|
new SpriteText { Text = "Display beatmaps from: TODO slider" },
|
||||||
|
new SpriteText { Text = "up to: TODO slider" },
|
||||||
|
};
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
18
osu.Game/Overlays/Options/SongSelectGraphicsOptions.cs
Normal file
18
osu.Game/Overlays/Options/SongSelectGraphicsOptions.cs
Normal file
@ -0,0 +1,18 @@
|
|||||||
|
using System;
|
||||||
|
using osu.Framework.Graphics.UserInterface;
|
||||||
|
|
||||||
|
namespace osu.Game.Overlays.Options
|
||||||
|
{
|
||||||
|
public class SongSelectGraphicsOptions : OptionsSubsection
|
||||||
|
{
|
||||||
|
protected override string Header => "Song Select";
|
||||||
|
|
||||||
|
public SongSelectGraphicsOptions()
|
||||||
|
{
|
||||||
|
Children = new[]
|
||||||
|
{
|
||||||
|
new BasicCheckBox { LabelText = "Show thumbnails" }
|
||||||
|
};
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
39
osu.Game/Overlays/Options/UpdateOptions.cs
Normal file
39
osu.Game/Overlays/Options/UpdateOptions.cs
Normal file
@ -0,0 +1,39 @@
|
|||||||
|
using System;
|
||||||
|
using OpenTK.Graphics;
|
||||||
|
using osu.Framework;
|
||||||
|
using osu.Framework.Graphics;
|
||||||
|
using osu.Framework.Graphics.Sprites;
|
||||||
|
using osu.Framework.Graphics.UserInterface;
|
||||||
|
using osu.Framework.Platform;
|
||||||
|
using osu.Game.Graphics.UserInterface;
|
||||||
|
|
||||||
|
namespace osu.Game.Overlays.Options
|
||||||
|
{
|
||||||
|
public class UpdateOptions : OptionsSubsection
|
||||||
|
{
|
||||||
|
private BasicStorage storage;
|
||||||
|
protected override string Header => "Updates";
|
||||||
|
|
||||||
|
public UpdateOptions()
|
||||||
|
{
|
||||||
|
Children = new Drawable[]
|
||||||
|
{
|
||||||
|
new SpriteText { Text = "TODO: Dropdown" },
|
||||||
|
new SpriteText { Text = "Your osu! is up to date" }, // TODO: map this to reality
|
||||||
|
new OsuButton
|
||||||
|
{
|
||||||
|
RelativeSizeAxes = Axes.X,
|
||||||
|
Text = "Open osu! folder",
|
||||||
|
Action = () => storage?.OpenInNativeExplorer(),
|
||||||
|
}
|
||||||
|
};
|
||||||
|
}
|
||||||
|
|
||||||
|
protected override void Load(BaseGame game)
|
||||||
|
{
|
||||||
|
base.Load(game);
|
||||||
|
this.storage = game.Host.Storage;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
23
osu.Game/Overlays/Options/VolumeOptions.cs
Normal file
23
osu.Game/Overlays/Options/VolumeOptions.cs
Normal file
@ -0,0 +1,23 @@
|
|||||||
|
using System;
|
||||||
|
using osu.Framework.Graphics;
|
||||||
|
using osu.Framework.Graphics.Sprites;
|
||||||
|
using osu.Framework.Graphics.UserInterface;
|
||||||
|
|
||||||
|
namespace osu.Game.Overlays.Options
|
||||||
|
{
|
||||||
|
public class VolumeOptions : OptionsSubsection
|
||||||
|
{
|
||||||
|
protected override string Header => "Volume";
|
||||||
|
|
||||||
|
public VolumeOptions()
|
||||||
|
{
|
||||||
|
Children = new Drawable[]
|
||||||
|
{
|
||||||
|
new SpriteText { Text = "Master: TODO slider" },
|
||||||
|
new SpriteText { Text = "Music: TODO slider" },
|
||||||
|
new SpriteText { Text = "Effect: TODO slider" },
|
||||||
|
new BasicCheckBox { LabelText = "Ignore beatmap hitsounds" }
|
||||||
|
};
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
111
osu.Game/Overlays/OptionsOverlay.cs
Normal file
111
osu.Game/Overlays/OptionsOverlay.cs
Normal file
@ -0,0 +1,111 @@
|
|||||||
|
//Copyright (c) 2007-2016 ppy Pty Ltd <contact@ppy.sh>.
|
||||||
|
//Licensed under the MIT Licence - https://raw.githubusercontent.com/ppy/osu/master/LICENCE
|
||||||
|
|
||||||
|
using System.Diagnostics;
|
||||||
|
using OpenTK;
|
||||||
|
using OpenTK.Graphics;
|
||||||
|
using OpenTK.Input;
|
||||||
|
using osu.Framework;
|
||||||
|
using osu.Framework.Graphics;
|
||||||
|
using osu.Framework.Graphics.Containers;
|
||||||
|
using osu.Framework.Graphics.Primitives;
|
||||||
|
using osu.Framework.Graphics.Sprites;
|
||||||
|
using osu.Framework.Graphics.Transformations;
|
||||||
|
using osu.Framework.Graphics.UserInterface;
|
||||||
|
using osu.Framework.Input;
|
||||||
|
using osu.Framework.Platform;
|
||||||
|
using osu.Game.Configuration;
|
||||||
|
using osu.Game.Online.API;
|
||||||
|
using osu.Game.Overlays.Options;
|
||||||
|
|
||||||
|
namespace osu.Game.Overlays
|
||||||
|
{
|
||||||
|
public class OptionsOverlay : OverlayContainer
|
||||||
|
{
|
||||||
|
internal const float SideMargins = 10;
|
||||||
|
private const float width = 400;
|
||||||
|
|
||||||
|
public OptionsOverlay()
|
||||||
|
{
|
||||||
|
Depth = float.MaxValue;
|
||||||
|
RelativeSizeAxes = Axes.Y;
|
||||||
|
Size = new Vector2(width, 1);
|
||||||
|
Position = new Vector2(-width, 0);
|
||||||
|
|
||||||
|
Children = new Drawable[]
|
||||||
|
{
|
||||||
|
new Box
|
||||||
|
{
|
||||||
|
RelativeSizeAxes = Axes.Both,
|
||||||
|
Colour = Color4.Black,
|
||||||
|
Alpha = 0.8f,
|
||||||
|
},
|
||||||
|
// TODO: Links on the side to jump to a section
|
||||||
|
new ScrollContainer
|
||||||
|
{
|
||||||
|
RelativeSizeAxes = Axes.Both,
|
||||||
|
ScrollDraggerOnLeft = true,
|
||||||
|
Children = new[]
|
||||||
|
{
|
||||||
|
new FlowContainer
|
||||||
|
{
|
||||||
|
AutoSizeAxes = Axes.Y,
|
||||||
|
RelativeSizeAxes = Axes.X,
|
||||||
|
Direction = FlowDirection.VerticalOnly,
|
||||||
|
Children = new Drawable[]
|
||||||
|
{
|
||||||
|
new SpriteText
|
||||||
|
{
|
||||||
|
Text = "settings",
|
||||||
|
TextSize = 40,
|
||||||
|
Margin = new MarginPadding { Left = SideMargins, Top = 30 },
|
||||||
|
},
|
||||||
|
new SpriteText
|
||||||
|
{
|
||||||
|
Colour = new Color4(235, 117, 139, 255),
|
||||||
|
Text = "Change the way osu! behaves",
|
||||||
|
TextSize = 18,
|
||||||
|
Margin = new MarginPadding { Left = SideMargins, Bottom = 30 },
|
||||||
|
},
|
||||||
|
new GeneralOptions(),
|
||||||
|
new GraphicsOptions(),
|
||||||
|
new GameplayOptions(),
|
||||||
|
new AudioOptions(),
|
||||||
|
new SkinOptions(),
|
||||||
|
new InputOptions(),
|
||||||
|
new EditorOptions(),
|
||||||
|
new OnlineOptions(),
|
||||||
|
new MaintenanceOptions(),
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
};
|
||||||
|
}
|
||||||
|
|
||||||
|
protected override bool OnMouseDown(InputState state, MouseDownEventArgs args) => true;
|
||||||
|
|
||||||
|
protected override bool OnKeyDown(InputState state, KeyDownEventArgs args)
|
||||||
|
{
|
||||||
|
switch (args.Key)
|
||||||
|
{
|
||||||
|
case Key.Escape:
|
||||||
|
if (State == Visibility.Hidden) return false;
|
||||||
|
|
||||||
|
State = Visibility.Hidden;
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
return base.OnKeyDown(state, args);
|
||||||
|
}
|
||||||
|
|
||||||
|
protected override void PopIn()
|
||||||
|
{
|
||||||
|
MoveToX(0, 300, EasingTypes.Out);
|
||||||
|
}
|
||||||
|
|
||||||
|
protected override void PopOut()
|
||||||
|
{
|
||||||
|
MoveToX(-width, 300, EasingTypes.Out);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
@ -61,14 +61,14 @@ namespace osu.Game.Overlays
|
|||||||
Icon = FontAwesome.gear,
|
Icon = FontAwesome.gear,
|
||||||
TooltipMain = "Settings",
|
TooltipMain = "Settings",
|
||||||
TooltipSub = "Change your settings",
|
TooltipSub = "Change your settings",
|
||||||
Action = OnSettings
|
Action = () => OnSettings?.Invoke()
|
||||||
},
|
},
|
||||||
new ToolbarButton
|
new ToolbarButton
|
||||||
{
|
{
|
||||||
Icon = FontAwesome.home,
|
Icon = FontAwesome.home,
|
||||||
TooltipMain = "Home",
|
TooltipMain = "Home",
|
||||||
TooltipSub = "Return to the main menu",
|
TooltipSub = "Return to the main menu",
|
||||||
Action = OnHome
|
Action = () => OnHome?.Invoke()
|
||||||
},
|
},
|
||||||
modeSelector = new ToolbarModeSelector
|
modeSelector = new ToolbarModeSelector
|
||||||
{
|
{
|
||||||
|
@ -177,7 +177,7 @@
|
|||||||
<Compile Include="OsuGame.cs" />
|
<Compile Include="OsuGame.cs" />
|
||||||
<Compile Include="OsuGameBase.cs" />
|
<Compile Include="OsuGameBase.cs" />
|
||||||
<Compile Include="Overlays\ChatConsole.cs" />
|
<Compile Include="Overlays\ChatConsole.cs" />
|
||||||
<Compile Include="Overlays\Options.cs" />
|
<Compile Include="Overlays\OptionsOverlay.cs" />
|
||||||
<Compile Include="Overlays\Toolbar.cs" />
|
<Compile Include="Overlays\Toolbar.cs" />
|
||||||
<Compile Include="Overlays\ToolbarButton.cs" />
|
<Compile Include="Overlays\ToolbarButton.cs" />
|
||||||
<Compile Include="Overlays\ToolbarModeButton.cs" />
|
<Compile Include="Overlays\ToolbarModeButton.cs" />
|
||||||
@ -196,6 +196,38 @@
|
|||||||
<Compile Include="Database\BeatmapMetadata.cs" />
|
<Compile Include="Database\BeatmapMetadata.cs" />
|
||||||
<Compile Include="Database\BeatmapInfo.cs" />
|
<Compile Include="Database\BeatmapInfo.cs" />
|
||||||
<Compile Include="Database\BaseDifficulty.cs" />
|
<Compile Include="Database\BaseDifficulty.cs" />
|
||||||
|
<Compile Include="Overlays\Options\LoginOptions.cs" />
|
||||||
|
<Compile Include="Overlays\Options\GeneralOptions.cs" />
|
||||||
|
<Compile Include="Overlays\Options\LanguageOptions.cs" />
|
||||||
|
<Compile Include="Overlays\Options\UpdateOptions.cs" />
|
||||||
|
<Compile Include="Overlays\Options\GraphicsOptions.cs" />
|
||||||
|
<Compile Include="Graphics\UserInterface\OsuButton.cs" />
|
||||||
|
<Compile Include="Overlays\Options\RendererOptions.cs" />
|
||||||
|
<Compile Include="Overlays\Options\LayoutOptions.cs" />
|
||||||
|
<Compile Include="Overlays\Options\DetailOptions.cs" />
|
||||||
|
<Compile Include="Overlays\Options\MainMenuOptions.cs" />
|
||||||
|
<Compile Include="Overlays\Options\SongSelectGraphicsOptions.cs" />
|
||||||
|
<Compile Include="Overlays\Options\GameplayOptions.cs" />
|
||||||
|
<Compile Include="Overlays\Options\GeneralGameplayOptions.cs" />
|
||||||
|
<Compile Include="Overlays\Options\SongSelectGameplayOptions.cs" />
|
||||||
|
<Compile Include="Overlays\Options\AudioOptions.cs" />
|
||||||
|
<Compile Include="Overlays\Options\AudioDevicesOptions.cs" />
|
||||||
|
<Compile Include="Overlays\Options\VolumeOptions.cs" />
|
||||||
|
<Compile Include="Overlays\Options\OffsetAdjustmentOptions.cs" />
|
||||||
|
<Compile Include="Overlays\Options\SkinOptions.cs" />
|
||||||
|
<Compile Include="Overlays\Options\InputOptions.cs" />
|
||||||
|
<Compile Include="Overlays\Options\MouseOptions.cs" />
|
||||||
|
<Compile Include="Overlays\Options\KeyboardOptions.cs" />
|
||||||
|
<Compile Include="Overlays\Options\OtherInputOptions.cs" />
|
||||||
|
<Compile Include="Overlays\Options\EditorOptions.cs" />
|
||||||
|
<Compile Include="Overlays\Options\OnlineOptions.cs" />
|
||||||
|
<Compile Include="Overlays\Options\AlertsPrivacyOptions.cs" />
|
||||||
|
<Compile Include="Overlays\Options\OnlineIntegrationOptions.cs" />
|
||||||
|
<Compile Include="Overlays\Options\InGameChatOptions.cs" />
|
||||||
|
<Compile Include="Overlays\Options\MaintenanceOptions.cs" />
|
||||||
|
<Compile Include="Overlays\Options\OptionsSection.cs" />
|
||||||
|
<Compile Include="Overlays\Options\OptionsSubsection.cs" />
|
||||||
|
<Compile Include="Graphics\UserInterface\LoadingAnimation.cs" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<ProjectReference Include="$(SolutionDir)\osu-framework\osu.Framework\osu.Framework.csproj">
|
<ProjectReference Include="$(SolutionDir)\osu-framework\osu.Framework\osu.Framework.csproj">
|
||||||
@ -215,6 +247,9 @@
|
|||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
<ItemGroup />
|
<ItemGroup />
|
||||||
<ItemGroup />
|
<ItemGroup />
|
||||||
|
<ItemGroup>
|
||||||
|
<Folder Include="Overlays\Options\" />
|
||||||
|
</ItemGroup>
|
||||||
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
|
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
|
||||||
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
|
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
|
||||||
Other similar extension points exist, see Microsoft.Common.targets.
|
Other similar extension points exist, see Microsoft.Common.targets.
|
||||||
|
Loading…
Reference in New Issue
Block a user