Skip to content
Tempo on GitHub (opens in a new tab)

2.2 Game packs

Each season’s field is one TOML file called the game pack. Routes plan around the elements it lists.

What a pack holds

The [field] table sets the field’s size, its coordinate origin and how the red half mirrors the blue half. These are the values in the REEFSCAPE 2025 pack:

TOML
[field]
lengthM = 17.548
widthM = 8.052
origin = "alwaysBlue"
symmetry = "rotational"

The rest of the pack is a list of field elements, each with an id and a shape:

  • [[obstacles]] are always routed around. The REEFSCAPE 2025 pack has the reef and the barge post.
  • [[terrain]] is avoided too, unless a leg calls .cross(...) with its id. Bumps and ramps go here.
  • [[regions]] are named areas that constraints and conditions refer to, such as the REBUILT’s neutralZone. A region with effect = "avoid" also keeps routes out of it. The REEFSCAPE 2025 pack has no regions because there was no point.

A pack normally lists only the blue elements, and symmetry builds the red copies under the same ids. Both alliances’ elements are planned around, so a blue auto still drives around the red reef. The same symmetry flips blue routes to red when the robot is on red (Alliance flipping).

An element is blue unless its alliance key says otherwise. A blue element gets a red copy, a "neutral" element is kept once with no copy, and an element written as "red" replaces the red copy of the blue element with the same id. The key doesn’t change whether an element blocks the robot.

How the robot finds it

Tempo.configure(...) loads the first pack it finds:

  1. A pack given to withGamePack(...).
  2. tempo/game.toml in the deploy folder. That’s src/main/deploy/tempo/game.toml.deploy/tempo/game.toml beside robot.py.
  3. The pack bundled with Tempo for its WPILib year.

To choose a bundled pack in code, over any deploy file, add withGamePack(...) to the config. It can go anywhere in the chain.

Java
public static final TempoConfig CONFIG = new TempoConfig()
    // ... the rest of the config
    .withGamePack(GamePacks.REBUILT_2026);
Python
CONFIG = (TempoConfig()
    # ... the rest of the config
    .with_game_pack(GamePacks.REBUILT_2026))
C++
inline const tempo::TempoConfig kConfig = tempo::TempoConfig{}
    // ... the rest of the config
    .with_game_pack(tempo::GamePacks::kRebuilt2026);

Robot startup fails with an error if the deploy file is invalid. When the folder holds other .toml files too, Tempo loads game.toml and prints a warning. A single pack with another name loads with a warning that says to rename it. Several packs with none named game.toml stop startup.

Tempo’s GUI previews paths with the same pack file. In the desktop app, its Field screen copies the active pack into the robot project once the project is connected. Loading a pack from a path or a string is covered in GamePack.

Tempo bundles three packs:

PackJava and PythonC++Field
REBUILT 2026GamePacks.REBUILT_2026GamePacks::kRebuilt202616.541 x 8.0693 m
REEFSCAPE 2025GamePacks.REEFSCAPE_2025GamePacks::kReefscape202517.548 x 8.052 m
CRESCENDO 2024GamePacks.CRESCENDO_2024GamePacks::kCrescendo202416.541 x 8.211 m

REBUILT 2026 is the default for both the 2026 and 2027 WPILib years (2027 changes post kickoff). It has these elements:

GroupIds
Obstacleshub, tower, trenchRight, trenchLeft
TerrainbumpLeft, bumpRight, depot
RegionsneutralZone, allianceZone
esc

Loading search...