mirror of
https://github.com/ppy/osu.git
synced 2025-01-15 08:12:56 +08:00
Try retrieving samples without bank names
Fallback for spinner bonus samples
This commit is contained in:
parent
04178058fb
commit
87f3184fcc
@ -55,8 +55,16 @@ namespace osu.Game.Skinning
|
|||||||
foreach (var lookup in info.LookupNames)
|
foreach (var lookup in info.LookupNames)
|
||||||
{
|
{
|
||||||
var ch = getSampleFunction($"Gameplay/{lookup}");
|
var ch = getSampleFunction($"Gameplay/{lookup}");
|
||||||
|
|
||||||
if (ch == null)
|
if (ch == null)
|
||||||
continue;
|
{
|
||||||
|
// Try fallback to non-bank samples.
|
||||||
|
var bank = lookup.Split('/').Last().Split('-')[0] + '-';
|
||||||
|
ch = getSampleFunction($"Gameplay/{lookup.Replace(bank, "")}");
|
||||||
|
|
||||||
|
if (ch == null)
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
|
||||||
ch.Volume.Value = info.Volume / 100.0;
|
ch.Volume.Value = info.Volume / 100.0;
|
||||||
return ch;
|
return ch;
|
||||||
|
Loading…
Reference in New Issue
Block a user