Game Development Reference
In-Depth Information
2. Drag-and-drop an instance of the TriviaCardScript to the GameObject.
Set the card width and height to 320,320 .
3. Drag-and-drop an instance of the TriviaCardScript to the GameObject.
Set the card width and height to 320,320 .
4. Drag-and-drop an instance of SimpleLifespanScript to the GameOb-
ject. Set the seconds parameter to 4 . This will make sure the pop up disap-
pears after it times out.
5. Repeat steps 1 to 3 for another texture named Level1Done.
Congratulations! These two Prefabs will be used to communicate the user's progress
through the learning objectives in level one. Create Prefabs by dragging-and-drop-
ping these GameObjects to the project tab. We will place these Prefabs into the
missionMgr script to finish configuring the level.
Creating the mission reward Prefabs
By exploiting the fact that a GameObject Prefab can contain any number of sub-
objects in the hierarchy, we can create Prefabs with any number of results to be
achieved in the world when a mission is complete. We will use this fact to aggregate
and pack together all of the results we want to achieve when the user accomplishes
their goals. We will use this fact to construct a reward for when the flags are all found
and a separate reward for when the flags are returned to the monument.
Search WWH ::




Custom Search