AssetDatabase.GetAssetBundleDependencies 

해당 API가 정상적으로 동작하지 않는다. string[0] 배열만을 리턴한다.

다른 API를 통해 같은 효과를 얻을 수 있다.


1
2
3
4
5
6
7
8
9
10
    public string[] GetAssetBundleDependencies(string assetBundleName)
    {        
        string[] assetPaths = AssetDatabase.GetAssetPathsFromAssetBundle(assetBundleName);
        string[] result = new string[assetPaths.Length];
        for (int i = 0; i < assetPaths.Length; i++)
        {
            result[i] = Path.GetFileNameWithoutExtension(assetPaths[i]);
        }
        return result;
    }
cs


'Unity > Tip' 카테고리의 다른 글

readable 설정되지 않은 Texture Copy  (0) 2018.12.25
단축키  (0) 2018.12.25

+ Recent posts