TracktypeLabels
Labels for rail types, road types and tram type
All track types are identified via 4-byte labels. The labels are unique within their type, but it is common that rail types and tram types use the same label for similar types.
Vehicles can check for their track type on a tile, but they only have access to their own type: On a level-crossing with all three tracks (rail, road, tram) trains can only check rail types, buses/trucks can only check road types, and trams can only check tram types.
Rail vs. tram
Rail and tram are very different wrt. game-play, but both are kind of rails. To unify labels, rail and tram should use the same labels, if the tracks are similar.
- RAIL for unelectrified rail and tram.
- ELRL for electrified rail and tram.
- FNCY for fancy-powered rail and tram.
Default labels
Rail type
These labels are used for the trains and tracks in the base game, as well as for train sets that are not rail-type-aware. Consequently, track NewGRFs should always override their properties, or at least make their tracks compatible to them.
Label | Rail Type |
---|---|
RAIL | Normal rail |
ELRL | electrified rail |
MONO | Monorail tracks |
MGLV | Maglev tracks |
Road types
By default there is only a single road type defined:
Label | Road Type |
---|---|
ROAD | Normal road |
However, if a NewGRF requires electrified "ELRD", an Action0 is sufficient to add this type and make it use the default road-ground and catenary sprites.
Tram types
By default there is only a single tram type defined:
Label | Tram Type |
---|---|
ELRL | Electrified rail |
However, if a NewGRF requires unelectrified "RAIL", an Action0 is sufficient to add this type and make it use the default tram-ground sprites.
Note: Please use the same label for tram types which already exist as rail types.
Standardized Railtype Scheme
Several members of the TT Forums have collaborated to define a rail type label scheme that allows for compatibility between train and track sets by different authors. At the same time it allows fancy stuff like axle weight limits, speed limits, different track and electrification types, etc. See Standardized Railtype Scheme.
The Standardized Railtype Scheme is not mandatory, and authors providing both trains and railtypes may have valid reasons to use labels outside the scheme. The Standardized Scheme cannot cover all possible cases, by design, as it would be too complex.
However even when using custom labels, it may be worth using Standardized Railtype labels:
- as fallbacks for trains when the custom label is not available (via NML railtypetable fallback lists)
- as alternates handled by a railtype with a custom label (via NML alternative_railtype_list or NFO prop 1D)
This will provide wider compatibility with other train and railtype grfs.
Non-standard railtype labels
The following labels were defined before the Standardized Railtype Scheme existed. Using these or not is at the discretion of individual grf authors, but generally, if an equivalent label exists in the Standardized Railtype Scheme, it's better to use that.
Label | Rail Type | ExpandNotes |
---|
Standardized Roadtype Scheme
Same story as the railtype one, also covers trams. See Standardized Roadtype Scheme
Non-standard roadtype labels
The following labels were defined before the Standardized Roadtype Scheme existed, but after alternative_roadtype_list and alternative_tramtype_list existed (meaning compatibility options allowed for quicker proliferation. Using these or not is at the discretion of individual grf authors, but generally, if an equivalent label exists in the Standardized Roadtype Scheme, it's better to use that. Ditto for tramtypes, but note that a label can be used twice, once for a roadtype and once for a tramtype.
Non-standard roadtypes
Label | Road Type | ExpandNotes |
---|
Non-standard tramtypes
Label | Road Type | ExpandNotes |
---|