/// <summary> /// 从路径预载异步游戏对象 /// </summary> /// <param name="resPath">路径</param> public static void PreLoadFromPath(string resPath) { if (!CachePrefabs.Contains(resPath)) { AssetSystem.LoadAssetAsyn(resPath, answer); } }
public void Start() { if (CachePrefabs.Contains(resPath)) { GameObject prefab = CachePrefabs[resPath] as GameObject; Perform(prefab); DestroyImmediate(this); } else { AssetSystem.LoadAssetAsyn(resPath, this); } }
public static void PreLoad(string path) { AssetSystem.LoadAssetAsyn(path, Instance); }