mirror of
https://github.com/ppy/osu.git
synced 2025-01-14 00:42:55 +08:00
Add source lookups for safety
This commit is contained in:
parent
7406e00bfc
commit
3da5eb6c8b
@ -110,9 +110,9 @@ namespace osu.Game.Rulesets.Osu.Skinning
|
||||
return null;
|
||||
}
|
||||
|
||||
public Texture GetTexture(string componentName) => null;
|
||||
public Texture GetTexture(string componentName) => source.GetTexture(componentName);
|
||||
|
||||
public SampleChannel GetSample(ISampleInfo sample) => null;
|
||||
public SampleChannel GetSample(ISampleInfo sample) => source.GetSample(sample);
|
||||
|
||||
public TValue GetValue<TConfiguration, TValue>(Func<TConfiguration, TValue> query) where TConfiguration : SkinConfiguration
|
||||
=> configuration.Value is TConfiguration conf ? query.Invoke(conf) : default;
|
||||
|
Loading…
Reference in New Issue
Block a user