Advanced Additive Scenes: Multi-Scene Editing. Now With Free Demo!

Update!! It’s been released: Advanced Additive Scenes - Multi-Scene Editing! | Utilities Tools | Unity Asset Store. There is also a DEMO version available. Original post below.

Hey guys,

I’ve been slaving away on a really useful plug-in which I’m tentatively calling “Advanced Additive Scenes”. I plan to release it shortly, after it goes through some more extensive testing. In order to explain what this plug-in does, I’ll have to explain Additive Scenes which Unity supports natively.

Scenes as Layers

You can think of a Scene as a layer in Photoshop. In Photoshop, you can combine multiple layers to compose an image. Likewise in Unity, you can combine multiple scenes to compose an image. Usually in your game, you will have many screens; at the very least a pause screen. You will want these screens to load without destroying your game state (they should layer over-top of your scene). Let’s take a look at this in Fling Theory:

In the picture above, you can see how the two scenes (the level and the pause menu) combine to compose the final image. You can achieve this by simply calling Application.LoadLevelAdditive() as opposed to Application.LoadLevel(). What are the advantages of Additive Scenes over Prefabs? Glad you asked, since you’re using a Scene instead of a Prefab, you are able to nest prefabs without your scene without running into the dreaded Nested Prefab issue.

Additive Scene Tools

Now that we’ve established this is a good thing, what are the limitations? Well for one, you cannot preview the combination of Level + Pause Menu without playing the game, and executing the LoadLevelAdditive() call. This is a slight work-flow issue because you would prefer to be able to use the WYSIWYG editor like usual. Enter: Advanced Additive Scenes. Using the plug-in, you are able to preview Additive Scenes in the editor:

This screenshot shows a SubScene configured to load the PauseMenu. By doing this, you are able to line-up your pause menu elements, see how the rendering order works, and tweak your shading/transparency. When you unlock the SubScene object, you are able to make changes to PauseMenu, and the best part is: All of the changes get saved back into the PauseMenu scene!

Beyond Menus

This alone is an amazing workflow improvement, but let’s take another look at Fling Theory and see how our levels are structured. Here is a typical level layout:

Notice how there are multiple rooms which comprise the level? Well, we can break up these rooms into SubScenes. Doing this makes sure the data for each room is saved into its own scene file. This allows multiple designers to work on the same level, as long as they are modifying separate rooms! This is a huge productivity boost for teams with multiple members. It helps alleviate issues that arise when multiple members work on the same scene. Let’s take a look at what this looks like:

Improved Collaboration

You can see that the level is broken up into multiple rooms, and each room has its own SubScene. This works extremely well for our two-man team since Doug and myself can both be working on the same level as long as we’re tweaking separate rooms. On more advanced projects, you would break-up the background from the puzzles and allow artists to tweak the look of the level which would never cause merge issues with the designer. Breaking up scenes by discipline (art, audio, design, programming) is a great way to get productivity boost; Unreal has been doing it for years.

I want to turn your attention over to the Inspector for a moment. You’ll notice there’s a few different options. With the Pause Menu, I set the Runtime Load Settings to “Don’t Load” which indicates my code will load the menu manually. On the other hand, when breaking up the level into rooms I chose “Bake Into Scene” which ensures the data lives in the scene in the final build. This option optimizes the loading time by ensuring all of the data is loaded at once, and Unity sees it as a single scene at runtime. This ensures there is no overhead associated with using this plug-in!

I plan to release this soon, after some more extensive testing. Let me know if you have questions/feedback/requests.

4 Likes

That does look like a mighty clever system. Looking forward to the release :slight_smile:

I agree, this looks mighty interesting. I will keep an eye out for this too!

Thanks guys! I love MegaFiers, Spooky :). I’ve integrated this plug-in in our main project now so we’ll be doing some extensive testing and hopefully release soon.

Just FYI for owners of other Coding Jar products, you may need to go into your library directory and remove the old Coding Jar folder before you can actually download the package. Not sure why but I couldn’t get Unity to actually import this package until I did this (Meaning clicking “Import” didn’t do anything Shrug )

For Mac Users
/Library/Unity/Asset Store/ in OS X

I look forward to using it, thanks Jodon.

The plug-in is officially released in beta! Advanced Additive Scenes - Multi-Scene Editing! | Utilities Tools | Unity Asset Store. There’s videos here:

Intro:

Angry Bots 1:

Angry Bots 2:

Do you have any options in place to adjust the padding of the info you have on the objects in the hierarchy? So many extensions offer info next to gameobjects and none of seem to take into account that other extensions do the same, so they end up having information overlapping.

You can change and/or disable the coloring. The icons are right-justified and only appear on the root of a SubScene. It comes with source code so you can always change it to your liking.

Jodon,

How does the plugin deal with subscenes having their own Beast Lightmapping?

I noticed in your AB2 video that the static sub scene didn’t have the lightmapping with it when viewed alone but did when viewed with the Main Scene. Related, moving those 3 poly surface GameObjects out of the static subscene would probably prevent baking the same lightmap in the static subscene?

Hey Jeff,

That’s correct the lightmap lives in the main scene, not the sub-scenes. What goal are you trying to achieve? Perhaps I could support the functionality you need.

Cheers.

This looks fantastic.

I have a question about lightmaps. I frequently split my larger scenes into smaller scenes that are lightmapped separately, then load them into the main scene using EditorApplication.OpenSceneAdditive() - this brings in the lightmaps, and means I don’t have to rebake the entire thing every time i make small changes in one area.

Will your plugin support this workflow?

Edit: this means i’d then bake occlusion culling, navmeshes etc in the main scene when everything is loaded in - would this also be supported?

Would it work together with sectr stream? I won’t use this on sectr-generated scenes, but on other parts of my main scene.

Right now, this won’t work because when you bake the main scene is loaded. I’m not sure I’d be able to support being able to rebake just a SubScene while you’re editing the main scene. I have not seen this workflow in Unity yet, my guess is you have to open up the SubScene to bake it, correct?

So far you could only use the plug-in to then view the scenes together, but would have to use your old workflow to actually do the baking. If this is an issue, I can fix it in the next version. Sounds like something people would like :).

Hi Jodon,

I had a similar question as yezzer. If I understand correctly, the plugin currently supports baked sub-scenes to be merged with the main scene.

However based on your response, am I correct in assuming that you are looking forward to adding the functionality of allowing one to bake only sub-scenes while working in the main scene? This would be an excellent addition and would be an immediate buy for me as this is something I have been looking to use in my pipeline for a while now.

Regards,
Sam

I have the same question. SECTR Stream compatibility would make this a buy from me.

In that case it will work. I have a feeling it would even work for the Sectr “Chunks” by placing the SubScene behaviour on their “chunk” since they are also using Unity Scenes as their format, but I can’t guarantee it as I don’t have their plug-in.

I am going to look into it, but I can’t promise anything. With this plug-in, I’m hitting a lot of limitations in how Unity handles things and trying to work around them. I fear that light mapping and occlusion culling may be one of those, but I’ll give it a shot.

Hello Jodon. Congrats on being the Asset Store 24 hour sale today.

I’m writing the loader for my game and I’m running into issues loading a level that contains SubScenes. I have two the primary scenes that get loaded first. The Game Manager scene and then the title screen. Once the Title screen is loaded, I load the parent scene that contains my terrain and misc. The Parent scene (Called “Island_1” in my log info attached below), contains 4 subscenes. Upon loading “Island_1” using LoadLevel (Via script or Playmaker), unity crashes with the log below. Is using Additive Scenes supported in this manner or once I have Advance Additive Scenes in my game, I must always use Scene Objects to load my game?

http://hastebin.com/raw/natabotajo

It should be supported in this manner. I’m kind of confused about this callstack, is this an editor crash or a runtime crash? Can you try the same scene loaded via a simple script that calls Application.LoadLevel() and see if it has the same issues? The crash appears to be in an internal Unity function in which I’ve already checked if the object is valid which scares me :).

Cheers.

Ok, I just tried a build and it seems to be working Runtime. But in editor is the problem. I just reproduced it in a test case. I PM’ed you a link to the example. The bug manifests when you do the following:

  • In Scene A

  • Call LoadAdditive Scene B

  • In Scene B

  • Call LoadAdditive Scene C

  • In Scene C

  • Scene C contains several Subscene objects

If Scene A were to load Scene C, there would be no problem. Because it is chained one more deep, this is where the problem manifests. So it may no be something you can control, but I would appreciate any help in working around it. Otherwise I’m going to have to rethink how I approach loading my game.

I’m on Mac OS X Mavericks, Unity 4.5.4 with Additive Scenes 1.5f

Example project PM’ed to you in a few minutes

Think I found it, I’ll send you a build in a couple of hours after I do some more extensive testing on it.