static List<AssetBundleBuild> GeneratorAssetbundleEntry() { string path = Application.dataPath + "/" + PackagePlatform.packageConfigPath; if (string.IsNullOrEmpty(path)) return null; string str = File.ReadAllText(path); Dict<string, ABEntry> abEntries = new Dict<string, ABEntry>(); PackageConfig apc = JsonUtility.FromJson<PackageConfig>(str); AssetBundlePackageInfo[] bundlesInfo = apc.bundles; for (int i = 0; i < bundlesInfo.Length; i++) { ABEntry entry = new ABEntry(); entry.bundleInfo = bundlesInfo[i]; if (!abEntries.ContainsKey(entry.bundleInfo.name)) { abEntries.Add(entry.bundleInfo.name, entry); } } List<AssetBundleBuild> abbList = new List<AssetBundleBuild>(); foreach (var rEntryItem in abEntries) { abbList.AddRange(rEntryItem.Value.ToABBuild()); } return abbList; }
public static ABEntryProcesser Create(ABEntry rABEntry) { ABEntryProcesser rEntryProcesser = null; rEntryProcesser = new ABEntryProcesser(); rEntryProcesser.Entry = rABEntry; return(rEntryProcesser); }
static List <AssetBundleBuild> GeneratorAssetbundleEntry() { string path = Application.dataPath + "/" + PackagePlatform.packageConfigPath; if (string.IsNullOrEmpty(path)) { return(null); } string str = File.ReadAllText(path); Dict <string, ABEntry> abEntries = new Dict <string, ABEntry>(); PackageConfig apc = JsonUtility.FromJson <PackageConfig>(str); AssetBundlePackageInfo[] bundlesInfo = apc.bundles; for (int i = 0; i < bundlesInfo.Length; i++) { ABEntry entry = new ABEntry(); entry.bundleInfo = bundlesInfo[i]; if (!abEntries.ContainsKey(entry.bundleInfo.name)) { abEntries.Add(entry.bundleInfo.name, entry); } } List <AssetBundleBuild> abbList = new List <AssetBundleBuild>(); foreach (var rEntryItem in abEntries) { abbList.AddRange(rEntryItem.Value.ToABBuild()); } return(abbList); }