static IEnumerator DisposeSceneAsync() { string[] scenePaths = Directory.GetFiles(ResourceConst.ScenePath, "*.unity"); if (scenePaths == null || scenePaths.Length < 1) { yield break; } for (int i = 0; i < scenePaths.Length; i++) { string scenePath = scenePaths[i]; PackAssetBundleUtlis.ShowProgress(i, scenePaths.Length, "分析场景:", scenePath); DisposeSingleScene(scenePath); yield return(1); } string[] sceneConfPaths = Directory.GetFiles(ResourceConst.ScenePath, "*.asset"); if (sceneConfPaths == null || sceneConfPaths.Length < 1) { yield break; } foreach (string sceneConf in sceneConfPaths) { _packTools.PushAssetBuild(sceneConf, ResourceConst.bundleSceneConf); } EditorUtility.ClearProgressBar(); }