Hi,
We’ve been using the latest Unity 5.1.0 for a bit but keep running into an issue with assetbundles, scenes and lightmaps.
So our situation is a little contrived but we have 1 scene in one bundle ( Unity doesn’t allow more than 1 right now with the new system ). The new assetbundle also does not allow any other assets to go into that bundle if there is a scene present / the functions to retrieve GetAssets from a bundle just return 0.
We lightmap the scene, a subfolder is generated with the correct assets.
We just load the scene raw in the editor via Application.LoadLevel, the level loads and looks fine
If we pack the scene into a bundle, the lightmaps are loaded in black.
If we take the lightmap assets and pack them into another assetbundle and load those first, the lightmaps are still loaded black.
Our scenes are located in our bundle folders so initially the lightmap data goes into the same bundle. I thought this was the problem initially but it doesn’t appear to make any difference.
We just call Application.LoadLevelAsync after we Load the bundle. I tried doing a LoadAllAssetsAsync on the bundle prior to no avail.
If we put the level into resources, it loads fine.
is there something obvious we’re missing?
The bizarre thing is that it works ok on a device sometimes…i guess ‘luck’ is part of it.
I’ve also looked at trying to manually load the lightmap resources, store off the params and restore on a scene load but this seems like an awful hack for something that should ‘just work’?
cheers