| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354 |
- namespace ET
- {
- public static class Define
- {
- public const string BuildOutputDir = "./Temp/Bin/Debug";
-
- public const string LogicVersion = "LogicVersion.txt";
- // 1 mono模式 2 ILRuntime模式 3 mono热重载模式
- public static int CodeMode = 3;
- public const int CodeMode_Mono = 1;
- public const int CodeMode_ILRuntime = 2;
- public const int CodeMode_Reload = 3;
-
- #if UNITY_EDITOR && !ASYNC
- public static bool IsAsync = false;
- #else
- public static bool IsAsync = true;
- #endif
-
- #if UNITY_EDITOR
- public static bool IsEditor = true;
- #else
- public static bool IsEditor = false;
- #endif
-
- public static UnityEngine.Object LoadAssetAtPath(string s)
- {
- #if UNITY_EDITOR
- return UnityEditor.AssetDatabase.LoadAssetAtPath<UnityEngine.Object>(s);
- #else
- return null;
- #endif
- }
-
- public static string[] GetAssetPathsFromAssetBundle(string assetBundleName)
- {
- #if UNITY_EDITOR
- return UnityEditor.AssetDatabase.GetAssetPathsFromAssetBundle(assetBundleName);
- #else
- return new string[0];
- #endif
- }
-
- public static string[] GetAssetBundleDependencies(string assetBundleName, bool v)
- {
- #if UNITY_EDITOR
- return UnityEditor.AssetDatabase.GetAssetBundleDependencies(assetBundleName, v);
- #else
- return new string[0];
- #endif
- }
- }
- }
|