So far we’ve done all of our work in a single scene. Generally however your game will be composed of multiple scenes. Let’s look at how you can create additional scenes and transition between them. Then we will look at an interesting tool enabling you to create indoor scenes using a 2D drawing.
Let’s create a magic stairway that transitions to another scene. In your scene, in the prefabs section, locate the Stairs, right click and select Create instance of this prefab.
A set of stairs will not appear in your scene like so:
In the Scenes tab, select the Settings button.
Rename your scene to something that makes sense.
Now back in the scene bar, click the Add button:
The name dialog will pop up, name the second scene. It will now show you a new scene in the editor. You can now switch between the active scenes using the scenes drop down in the scene menu:
Now that we have two scenes available, switch back to sceneOne, and select our newly created staircase. Now add a On Proximity do something, set the TestArea to the most applicable shape and the size to encompass the bounds of the staircase (or on a single step if you prefer)
Set the Near to what field to The current active camera, Trigger when to Enter Radius. Now we set the action to Cameras and Scenes->Switch to another scene.
In the newly created actions properties, set the Scene to your second scene:
Now play your game. When you camera moves within the boundaries of the staircase, boom, the other scene is loaded.
Now let’s look at creating a room level. In the Create panel choose the Create a room mesh:
You can now paint a room from above on a 2D map, using a combination of walls and floor types:
When done, click OK and your room will be generated:
This provides a quick and diry way of creating enclosed spaces. You can now tweak the generated shape using CopperCube’s built in polygon editing tools, available under Polygon Editing: