Level Editor/Entities/Payload Track
| Payload Track | |
|---|---|
| Made with | Functional > Payload Track |
| What it is | A railed route with a cart on it, driven by the gamemode |
| In the game | Yes, it is exported with the map |
A payload track is a railed path with a cart on it. You lay the track in the editor; the gamemode script decides when and how fast the cart moves, and what reaching a checkpoint means. The viewport draws the track as the game will lay it: rails, sleepers, checkpoint plates and the end.
Laying a track
- Choose Functional > Payload Track.
- Click along the route to drop anchors, start first. Each anchor is lifted 0.22 m off the surface you click, to the rail top, so the rails sit on the floor.
- Alt+click drops a sharp anchor (a corner); others are smooth (a curve).
- Enter or a double-click finishes the track (two anchors at least). Backspace takes back the last anchor; Esc abandons it.
Editing a track
Select a track (or one of its anchors) with the tool active, or finish laying one. Then:
- drag an anchor to move it;
- click the track to add an anchor there;
- click anywhere else to extend the track from its nearer end;
- Alt+click an anchor to make it sharp or smooth;
- press Delete over an anchor to take it out.
Enter or Esc lets go of the track. Each edit is one undo step. The scene tree's right-click menu also has Edit Path, Insert Path Anchor and Reverse Path (start <-> end).
Shaping: a straight run up a ramp needs a sharp anchor at each end to stay on the ramp.
Name: the track's name in the scene tree is the name the gamemode script uses for it. Rename it there.
A Path Brush drawn on the same anchors with Top below line 0.22 makes a bed under the track.
Anchor inspector
| Setting | Type | Default | What it does |
|---|---|---|---|
| Smooth | Check box | On | The track curves through this anchor. Off makes it a sharp corner between straight runs. |
| Checkpoint | Check box | Off | Marks a checkpoint. What reaching it does is up to the gamemode (a payload mode might add time and stop the cart rolling back past it). Ignored on the first and last anchors: the start is not a checkpoint and the end is the goal. |
| Marker | Text | empty | A name for this point of the track, for the gamemode script to read: where a door opens, a hill starts, the speed changes. It means nothing until a script uses it. Every anchor may have one, first and last included, and names on one track must differ. |
In the game
The cart carries a push zone that moves with it (its label is the track's name) and a dispenser that the mode can turn on for one team. Two tracks with the same name are exported under different names; the export log says which name the script sees.
For scripting the cart, see Payload tracks in scripts.