Sequences

The following describes each available game flow sequence type and the required parameters for each. Note that while this table is displayed in alphabetical order, care must be taken to define sequences in the correct order. Refer to the default game flow for examples.

Sequence Parameter Type Description
loop_game N/A Plays the main game loop.
level_complete N/A Ends the current level and plays the next one, if available.
exit_to_title N/A Returns to the title level.
level_stats N/A Displays the end of level statistics for the current level. In a Gym level, this fades the screen to black.
total_stats path String Displays the end of game statistics with the given picture file shown as a background.
display_picture path String Displays the specified picture for a fixed time. Files that are needed to function only with a specific aspect ratio can be placed in a directory adjacent to the main image, named according to the aspect ratio – for example, 4x3/title.png or 16x10/title.png. The game won't attempt to match these precisely; instead, it will select the file with the aspect ratio closest to the game's viewport. The main image designated by path is presumed to have a 16:9 aspect ratio for this purpose, and as such there's no need for 16x9-specific directory.
This logic applies to all images.
display_time Double Number of seconds to display the picture for (default: 5).
fade_in_time Double Number of seconds to do the fade-in animation, if enabled (default: 1).
fade_out_time Double Number of seconds to do the fade-out animation, if enabled (default: 0.33).
loading_screen¹ path String Shows a picture prior to loading a level. Functions identically to display_picture, except these pictures can be enabled/disabled by the user with the loading screen option in the config tool.
display_time Double
fade_in_time Double
fade_out_time Double
play_cutscene cutscene_id Integer Plays the specified cinematic level (from the cutscenes).
play_fmv fmv_id String Plays the specified FMV. fmv_id must be a valid index into the fmvs root key.
flip_map¹ N/A Triggers the flip map.
give_item object_id Integer / String Adds the specified item and quantity to Lara's inventory.
quantity Integer
add_secret_reward² object_id Integer / String Adds the specified item to the current level's list of rewards for collecting all secrets.
quantity Integer
mesh_swap¹ object1_id Integer Swaps the given mesh ID between the given objects.
object2_id Integer
mesh_id Integer
play_music music_track Integer Plays the given audio track.
remove_ammo N/A Any combination of these sequences can be used to modify Lara's inventory at the start of a level. There are a few simple points to note:
  • remove_weapons does not remove the ammo for those guns, and equally remove_ammo does not remove the guns. Each works independently of the other.
  • These sequences can also work together with give_item - so, item removal is performed first, followed by addition.
remove_weapons N/A
remove_medipacks N/A
remove_flares² N/A
remove_scions¹ N/A
set_cutscene_pos¹ x Integer Sets the camera's position.
y Integer
z Integer
set_cutscene_angle value Integer Sets the camera's angle.
setup_bacon_lara¹ anchor_room Integer Sets the room number in which Bacon Lara will be anchored to enable correct mirroring behaviour with Lara.
enable_sunset² N/A Enables the sunset effect, like in Bartoli's Hideout. At present, this feature is hardcoded to gradually darken the game 40 minutes into playing a level.
set_lara_start_anim² value Integer Applies the selected animation to Lara when the level begins. This is used, for example, in the Offshore Rig of Tomb Raider II.
disable_floor value Integer Configures a specific height (with 256 representing 1 click and 1024 representing 1 sector) to define an abyss that will invariably lead to Lara's death if she falls into it. Additionally, it employs special rendering to ensure it isn't treated as solid ground. This is used, for example, in the Floating Islands of Tomb Raider II.

¹ Tomb Raider 1 only.
² Tomb Raider 2 only.