static private void CacheDependencies(string path, string abName) { path.Replace("\\", "/"); string[] strs = AssetDatabase.GetDependencies(path); foreach (string str in strs) { AssetRefCache cache; if (m_CacheDics.TryGetValue(str, out cache)) { if (cache.m_ABNames.Equals(abName)) { cache.AddRef(); if (!m_SplitAssetDics.ContainsKey(str)) { m_SplitAssetDics.Add(str, cache); } } } else { cache = new AssetRefCache(); cache.m_ABNames = abName; m_CacheDics.Add(str, cache); } } SetAssetBundleName(abName, path); }
private static void CacheDependencies(string path, string abName) { path.Replace("\\", "/"); string[] strs = AssetDatabase.GetDependencies(path); foreach (string str in strs) { AssetRefCache cache; if (m_CacheDics.TryGetValue(str, out cache)) { if (cache.m_ABNames.Equals(abName)) { cache.AddRef(); if (!m_SplitAssetDics.ContainsKey(str)) m_SplitAssetDics.Add(str, cache); } } else { cache = new AssetRefCache(); cache.m_ABNames = abName; m_CacheDics.Add(str, cache); } } SetAssetBundleName(abName, path); }