BundleSystem.EditorAssetMap.EditorAssetMap C# (CSharp) Method

EditorAssetMap() public method

public EditorAssetMap ( BundleSystem.AssetbundleBuildSettings settings ) : System.Collections.Generic
settings BundleSystem.AssetbundleBuildSettings
return System.Collections.Generic
        public EditorAssetMap(AssetbundleBuildSettings settings)
        {
            var assetPath = new List<string>();
            var loadPath = new List<string>();
            foreach (var setting in settings.BundleSettings)
            {
                assetPath.Clear();
                loadPath.Clear();
                var folderPath = UnityEditor.AssetDatabase.GUIDToAssetPath(setting.Folder.guid);
                Utility.GetFilesInDirectory(string.Empty, assetPath, loadPath, folderPath, setting.IncludeSubfolder);
                var assetList = new Dictionary<string, List<string>>();
                for(int i = 0; i < assetPath.Count; i++)
                {
                    if(assetList.TryGetValue(loadPath[i], out var list))
                    {
                        list.Add(assetPath[i]);
                        continue;
                    }
                    assetList.Add(loadPath[i], new List<string>() { assetPath[i] });
                }
                m_Map.Add(setting.BundleName, assetList);
            }
        }