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

Using the setupLevel3 Prefab

The setupLevel3 Prefab will be activated when the user presses the popup_Level3Start button. It will initialize the NPCs for the level, place them in random locations in the world, and set up the state tracking logic that determines if the player achieves success. Perform the following steps to use the setupLevel3 Prefab:

  1. Locate the Prefab named setupLevel2 beneath _level2, and rename it setupLevel3. Duplicate the SetupMissionTwo script from mission two, and rename the duplicate to SetupMissionThree. Place the duplicate in the folder named Chapter9 to keep your assets organized.
  2. Add an instance of this script to the setupLevel3 object.
  3. Inside MonoDevelop, change the class declaration to SetupMissionThree so that it matches ...

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