Book Image

Creating E-Learning Games with Unity

By : David Horachek
Book Image

Creating E-Learning Games with Unity

By: David Horachek

Overview of this book

Table of Contents (17 chapters)
Creating E-Learning Games with Unity
About the Author
About the Reviewers

Defining the framework for mission two

As with mission one, we will organize our game objects into hierarchies as shown in the following screenshot:

The _global GameObject hierarchy will contain objects that persist for the entire lifespan of the game, and we will develop other hierarchies for objects that persist during a specific level.

To begin, let's create a new scene file for the level. Name the scene TESTBED2. Inside this scene, let's add two empty game objects at the root level, placed at (0,0,0) as with the first level. Name them _global and _level2.

  1. Under _global, add the layer, camera, and GameObject. Recall that these objects and their scripts persist across all levels.

  2. Under _level2, we will add level 2's specific GameObjects. As we create them throughout this chapter, we will add them to the hierarchy formed with the object named _level2 as the root.

    The following objects will be placed in this hierarchy:

    • _splineDataA and _splineDataB: These are two collections of control points...