O'Reilly logo

Creating E-Learning Games with Unity by David Horachek

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Refactoring our work

Now that we have a fully functional system for loading and unloading scene files, we will dedicate our attention to the integration and refactoring of the remaining GameObjects, hierarchies, and scripts.

The pop-up system

To refactor our pop-up system, perform the following steps to complete the moving of our game content from the testbed scene file to the MAIN scene file.

Updating level 3 pop ups

Let's begin by refactoring the pop-up panel system:

  1. Under _global, ensure that the player (named Player1), camera (named MainCamera), and game (named Game) child objects can be found. Also make sure that a GameObject of type GUITexture named score is present as shown in the following screenshot:
  2. We will change the behavior of the pop ups ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required