- Home /
Difference between LoadLevelAdditive and LoadLevelAdditiveAsync
I'm putting together a fairly large world where I'll need to stream in multiple scenes at a time based on a character position. I've read about LoadLevelAdditive and LoadLevelAdditiveAsync from the unity docs, but am curious if people could elaborate on the differences. It seems as though LoadLevelAdditive will work, as long as I track what levels should be loaded/unloaded at a given time. However, there seems to be additional benefits by using the alternative (being that Unity Pro is also required). Keep in mind, I would prefer if there were no loading screens and that performance not take a huge hit while loading in other parts of the world.
Additionally, when streaming, do developers typically use a square grid system, or are there advantages to using a grid system that does not consist of square chunks? I can imagine that a hex base grid system may have performance advantages.
Answer by whydoidoit · Apr 30, 2013 at 06:58 PM
The difference is that using LoadLevelAdditive your game will pause while the level is loaded. The Async version will load it in the background and then add it when it's finished (or if you use the new allowSceneActivation property of the AsynOperation you get back from LoadLevelAdditiveAsync it won't be added until you are ready for it).
I would suggest the best thing to do would be this.
Identify areas where the player can go next.
Load all of those areas with LoadLevelAdditiveAsync
When the player leaves an area, recalculate which areas to load and discard irrelevant ones if memory is tight.
Thanks - this clears up the distinction between the two. Beyond the pause that will happen when using LoadLevelAdditive and being able to specify the load when I'm ready, are there any other advantages to using the aforementioned loading option? Seems like I can use LoadLevelAdditive as a temporary solution until I'm ready to purchase the full version.
BTW don't post comments as Answers. On UA Answer means Solution and not Reply - there's an add new comment button under every post.