mirror of
https://github.com/ppy/osu.git
synced 2024-11-06 10:47:28 +08:00
Fix skin texture lookups not handling paths with extensions
This commit is contained in:
parent
5b29ddd2ed
commit
fb9fe4213d
@ -443,9 +443,7 @@ namespace osu.Game.Skinning
|
||||
string lookupName = name.Replace(@"@2x", string.Empty);
|
||||
|
||||
float ratio = 2;
|
||||
string twoTimesFilename = Path.HasExtension(lookupName)
|
||||
? @$"{Path.GetFileNameWithoutExtension(lookupName)}@2x{Path.GetExtension(lookupName)}"
|
||||
: @$"{lookupName}@2x";
|
||||
string twoTimesFilename = $"{Path.ChangeExtension(lookupName, null)}@2x{Path.GetExtension(lookupName)}";
|
||||
|
||||
var texture = Textures?.Get(twoTimesFilename, wrapModeS, wrapModeT);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user