layer_traffic¶
Source: base/tealdef/gui/layers/layer_traffic.d.tl
Notes
The "Traffic" map layer (button menu.layers.trafficButton).
LayerTraffic¶
record global base/tealdef/gui/layers/layer_traffic.d.tl:3
global record LayerTraffic
Load: local layer_traffic = ug_require "/gui/layers/layer_traffic.tl"
Notes
The "Traffic" layer, which colors roads and vehicles by congestion.
Fields
| Name | Type | Description |
|---|---|---|
Legend |
Recipe0 |
Recipe of the layer legend. used 1× in the base game |
Layer |
Recipe<LayersButtonRidge.LayerContentParam> |
Recipe of the layer window content. used 1× in the base game |
HudIconMaster |
Recipe2<Builtin.HudIconParam, LayersButtonRidge.HudIconUserParam> |
HUD icon recipe of the layer; default icons for vehicles, notifications and the traffic congestion rating for towns. used 1× in the base game |
Functions
getConfig() : LayerConfig base/tealdef/gui/layers/layer_traffic.d.tl:4
Call as layer_traffic.getConfig
Notes
Builds the layer config.
Returns LayerConfig: A new LayerConfig that colors the network, transport vehicles and land vehicles by congestion (jammed, intermediate, fluid).
getHudIconPreFilter() : {Engine.ComponentType} base/tealdef/gui/layers/layer_traffic.d.tl:7
Call as layer_traffic.getHudIconPreFilter
Notes
Component types that get HUD icons in this layer.
Returns {Engine.ComponentType}: TRANSPORT_VEHICLE and TOWN.