mirror of
https://github.com/ppy/osu.git
synced 2026-06-05 12:44:05 +08:00
Revert skin legacy version changes
This commit is contained in:
@@ -20,8 +20,6 @@ namespace osu.Game.Skinning
|
||||
new Color4(18, 124, 255, 255),
|
||||
new Color4(242, 24, 57, 255),
|
||||
});
|
||||
|
||||
Configuration.ConfigDictionary["Version"] = "2";
|
||||
}
|
||||
|
||||
public static SkinInfo Info { get; } = new SkinInfo
|
||||
|
||||
@@ -10,7 +10,7 @@ namespace osu.Game.Skinning
|
||||
/// </summary>
|
||||
public class DefaultSkinConfiguration : SkinConfiguration
|
||||
{
|
||||
public DefaultSkinConfiguration(string version)
|
||||
public DefaultSkinConfiguration()
|
||||
{
|
||||
ComboColours.AddRange(new[]
|
||||
{
|
||||
@@ -19,13 +19,6 @@ namespace osu.Game.Skinning
|
||||
new Color4(18, 124, 255, 255),
|
||||
new Color4(242, 24, 57, 255),
|
||||
});
|
||||
|
||||
ConfigDictionary["Version"] = version;
|
||||
}
|
||||
|
||||
public DefaultSkinConfiguration()
|
||||
: this("1")
|
||||
{
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -39,7 +39,7 @@ namespace osu.Game.Skinning
|
||||
using (LineBufferedReader reader = new LineBufferedReader(stream))
|
||||
Configuration = new LegacySkinDecoder().Decode(reader);
|
||||
else
|
||||
Configuration = new DefaultSkinConfiguration("latest");
|
||||
Configuration = new DefaultSkinConfiguration();
|
||||
|
||||
if (storage != null)
|
||||
{
|
||||
@@ -71,19 +71,6 @@ namespace osu.Game.Skinning
|
||||
case GlobalSkinColour colour:
|
||||
return SkinUtils.As<TValue>(getCustomColour(colour.ToString()));
|
||||
|
||||
case LegacySkinConfiguration legacy:
|
||||
switch (legacy)
|
||||
{
|
||||
case LegacySkinConfiguration.LegacyVersion:
|
||||
var versionString = GetConfig<string, string>("Version")?.Value ?? "1";
|
||||
if (!double.TryParse(versionString, out double version))
|
||||
version = versionString == "latest" ? 2.7 : 1.0;
|
||||
|
||||
return SkinUtils.As<TValue>(new BindableDouble(version));
|
||||
}
|
||||
|
||||
break;
|
||||
|
||||
case SkinCustomColourLookup customColour:
|
||||
return SkinUtils.As<TValue>(getCustomColour(customColour.Lookup.ToString()));
|
||||
|
||||
|
||||
@@ -1,10 +0,0 @@
|
||||
// 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.
|
||||
|
||||
namespace osu.Game.Skinning
|
||||
{
|
||||
public enum LegacySkinConfiguration
|
||||
{
|
||||
LegacyVersion,
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user