Graphics Reference
In-Depth Information
GAME CONTROL
The scripts in this folder are about overall game state control. In the example files,
you will find
BattleController and GlobalBattleManager—This script is used for deathmatch-
style scoring and game state logic.
RaceController and GlobalRaceManager—This script contains the base logic for
racing games, such as lap counting and position tracking.
SceneManager—This script deals with the loading of scenes as well as with
incremental game scene management (as used in the Interstellar Paranoids
example game of this topic).
INPUT
Different player and game types require different control systems or input meth-
ods. Any common scripts dealing with input go in this folder.
S PAW N I N G
Scripts related to spawning may be found here, which includes code to spawn
objects when triggers are fired or to spawn paths for dynamic waypoint fol-
lowing objects.
UTILITY
The Utility folder is home to small helper scripts, such as the timer class or a script
to automatically spin a gameObject.
WEAPONS
Any weapons-related scripts outside of the base framework may be found here.
The scripts in this chapter will be used in various places later on in the example games
parts of this topic.
This chapter will look in detail at the following:
4.2 The timer class
4.3 Scripts used for spawning
4.4 A script to set gravity
4.5 A script that simulates friction
4.6 Cameras
4.7 Input scripts
Search WWH ::




Custom Search