| Level Design / Level Parameter Editing / Level Routines
| The Level Routines tab in the Levels Window contains controls used to specify which routines are performed when certain events occur in a level. The level can be configured to perform routines periodically, when beginning, when the player beats the level, when the player dies, and when the game is over.
Specifying Routines | The Level Routines tab is divided into five sets of routine selection controls, making it possible to specify which routine is performed when each of the five routine triggering events occur. Each set of controls consists of a Perform Routine checkbox and a routine selection pop-up menu, as shown below. Each set of controls also includes an edit button which may be used to edit the level's routines.
Perform Routine Periodically | To make one of the level's routines perform itself at periodic intervals, check the Perform Routine Periodically checkbox and select the desired routine from the associated Routine to Perform pop-up menu. The value entered in the field under the pop-up menu determines how frequently the periodic routine is performed, as measured in ticks. Since there are 30 ticks per second, a value of 30 causes the routine to be performed once per second. A value of 60, for example, would cause the routine to be performed once every two seconds.
Perform Routine When Level Begins | To make one of the level's routines perform itself immediately when the level begins, check the Perform Routine When Level Begins checkbox and select the desired routine from the associated Routine to Perform pop-up menu. Routines that are performed when levels begin are often used to control camera movement, creating cinematic introductory sequences.
Perform Routine When Player Beats Level | To make one of the level's routines perform itself when the player completes the level, check the Perform Routine When Player Beats Level checkbox and select the desired routine from the associated Routine to Perform pop-up menu. The selected routine will be performed as soon as the player accomplishes the level goals, whether they involve defeating a boss character or entering a specific hot zone.
Perform Routine When Player Dies | To make one of the level's routines perform itself when the player dies, check the Perform Routine When Player Dies checkbox and select the desired routine from the associated Routine to Perform pop-up menu. The selected routine will be performed when the player is killed by an enemy attack or when the player falls into a pit.
Perform Routine When Game Is Over | To make one of the level's routines perform itself when the game is over, check the Perform Routine When Game Is Over checkbox and select the desired routine from the associated Routine to Perform pop-up menu. The selected routine will be performed as soon as the player loses his last remaining life.