This commit is contained in:
@@ -120,6 +120,10 @@ namespace ShrinkApp
|
||||
[CreateAssetMenu(fileName = "ShrinkAppSettings", menuName = "ShrinkSDK/应用/应用设置")]
|
||||
public class ShrinkAppSettings : ScriptableObject
|
||||
{
|
||||
public const string PreferredResourcesPath =
|
||||
"GameAssets/Runtime/Data/ShrinkSDK/ShrinkAppSettings";
|
||||
public const string LegacyResourcesPath = "ShrinkAppSettings";
|
||||
|
||||
private static ShrinkAppSettings? _instance;
|
||||
|
||||
public static ShrinkAppSettings Instance
|
||||
@@ -129,7 +133,9 @@ namespace ShrinkApp
|
||||
if (_instance != null)
|
||||
return _instance;
|
||||
|
||||
_instance = Resources.Load<ShrinkAppSettings>("ShrinkAppSettings");
|
||||
_instance = Resources.Load<ShrinkAppSettings>(PreferredResourcesPath);
|
||||
if (!_instance)
|
||||
_instance = Resources.Load<ShrinkAppSettings>(LegacyResourcesPath);
|
||||
|
||||
#if UNITY_EDITOR
|
||||
if (!_instance)
|
||||
|
||||
Reference in New Issue
Block a user