I’m having an issue with loading asset bundle dependencies with Unity 5’s new system. Here’s the problem: I’m loading Asset Bundle A which has Asset Bundle B as a dependency, when I load A the assets that it shares with B are not loaded, fine… so I make sure I always load B first. Even if I do this the assets from B are not present (MissingReferenceException) when I load A. The asset in question is a prefab referenced in A, that is built into B. Hopefully that is not too hard to follow. In the manifest it does properly say that A has B as a dependency.
Some things to note: I’m not tagging things in the editor, I’m creating an AssetBundleBuild[ ] in code, gathering the paths for all the bundles and passing it in to BuildPipeline.BuildAssetBundles using only the BuildAssetBundleOptions.UncompressedAssetBundle option.
I’m also renaming/moving the asset bundles after they’re built. I do this so that file structure/casing matches the file structure we have for the assets in the project, since Unity lower cases/dumps everything into one folder. Doing this makes it much easier to load things differently (LoadAssetAtPath in the Editor for instance), as everything has the same path, just a different root. We don’t always want to have to rebuild asset bundles and load from them.
Could either of those things be breaking things, so Unity forgets how these 2 bundles should be connected?
As for code, I’m simple using AssetBundle.CreateFromFile to load the asset bundles and AssetBundle.LoadAsset or AssetBundle.LoadAllAssets to load assets.
Any help appreciated, thanks!