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:
Locate the Prefab named
setupLevel2
beneath_level2
, and rename itsetupLevel3
. Duplicate theSetupMissionTwo
script from mission two, and rename the duplicate toSetupMissionThree
. Place the duplicate in the folder namedChapter9
to keep your assets organized.Inside
MonoDevelop
, change the class declaration toSetupMissionThree
so that it matches the name of the script as shown in the following code:public class SetupMissionThree : MonoBehavior
We will use the same pattern to choose random NPC locators as we did for the QuizNpc locators in mission two. We will remove the
CorrectPopups
list...