public T Load <T>(string assetPath) where T : UnityEngine.Object
        {
            Debug.Log("assetPath " + assetPath);
            var req = Assets.LoadAsset(assetPath, typeof(T));

            RegisterPool(ref req);
            return(req.asset as T);
        }
Beispiel #2
0
        public UnityEngine.Object Load(string assetPath, Type type)
        {
            Debug.Log("assetPath " + assetPath);
            var req = Assets.LoadAsset(assetPath, type);

            RegisterPool(ref req);

            return(req.asset);
        }