public int Execute(ref EditorSystemContext context, EditorEvent assetEvent) { if (assetEvent == EditorEvent.Enable) { #if UNITY_EDITOR string path = GetOutputPath(); if (!string.IsNullOrEmpty(path)) { string dirname = AssetBundleEditorHelper.GetDirectoryName(path); string allabpath = path + "/" + dirname; if (File.Exists(allabpath) && AssetBundleLoadManager.mIns != null) { int retcode = 0; try { var allmanifest = AssetBundleLoadManager.mIns.GetManifest(allabpath); if (allmanifest != null) { if (context.Manifests == null) { context.Manifests = new Dictionary <string, AssetBundleBuildInfo>(); } else { context.Manifests.Clear(); } var ablist = allmanifest.GetAllAssetBundles(); foreach (var assetbundlename in ablist) { AssignMainfest(ref context, allmanifest, path, assetbundlename); } } } catch (Exception e) { Debug.LogError(e); retcode = -1; } return(retcode); } } #endif } return(0); }