Hi dears:
I think some kind of resources like Sprite / Texture / Mesh / Atlas should be the unique resouce, isn’t ?
the situation is I have 2 UI, and they are reference the same Sprite(Pic1), the sprite was paking to button.ab(assetbundle), if I load button.ab and Load UI1, then Unload(false) them, later reload button.ab and Load UI2, the Atlas Texture was Repeat and Pic was Repeat Too…
is it means that I should not Unload the shared assetbundle? or any other way can I avoid memory repeating?
I tried do not Unload button.ab, it was fine, but some article notice that IOS do not allow the loaded assetbundle count more than 256 ? Thanks for any replay
Runing on Unity5.6.1f1
any solution?
Up Up Up
I believe if you unload the assetbundle and you load it again, it will spawn up a new instance. Trying to load the same material from the newly loaded assetbundle will spawn a new instance of the material, this is working as intended I believe.
Here is the documentation to explain the mechanism:
One way you can prevent this is to load your asset bundle and don’t unload it when the scene is running, why would you unload it anyway if you are gonna access it more than once? :). When you are moving away from the scene, unload the asset bundle.