Rally Utility Colors
Constants module defining all color values and visual parameters used throughout the rally editor and pacenote system. Colors are RGB float arrays `{r, g, b}` or ImGui `ImVec4` for UI elements.
Constants module defining all color values and visual parameters used throughout the rally editor and pacenote system. Colors are RGB float arrays {r, g, b} or ImGui ImVec4 for UI elements.
Color Constants
| Key | Value | Description |
|-----|------
| M.new_pacenote_cursor_linkToWidth | number | 0.25 |
| M.new_pacenote_cursor_linkFromWidth | number | 1.0 |
| M.new_pacenote_cursor_linkHeightRadiusShinkFactor | number | 0.5 |
| M.new_pacenote_cursor_alpha | number | 0.8 |
| M.new_pacenote_cursor_clr_ce | any | M.clr_light_red |
| M.new_pacenote_cursor_clr_cs | any | M.clr_light_green |
| M.new_pacenote_cursor_clr_link | any | M.clr_white |
| M.waypoint_planeAlphaFactor | number | 3.2 |
| M.waypoint_shapeAlpha_intersectPlane | number | 0.97 |
| M.waypoint_textAlpha_hover | number | 1.0 |
| M.waypoint_alpha_selected | number | 0.3 |
| M.waypoint_alpha_shape_background | number | 0.3 |
| M.waypoint_alpha_text_background | number | 0.3 |
| M.waypoint_clr_background | any | M.clr_grey_dark |
| M.waypoint_clr_sphere_selected | any | M.clr_white |
| M.waypoint_clr_txt_bg | any | clr_label_bg |
| M.waypoint_clr_txt_fg | any | clr_label_fg |
| M.waypoint_clr_ce_adjacent_bg | any | M.clr_red_dark |
| M.waypoint_clr_ce_adjacent | any | M.clr_red_pastel |
| M.waypoint_clr_cs_adjacent_bg | any | M.clr_green_dark |
| M.waypoint_clr_cs_adjacent | any | M.clr_green_pastel |
| M.pacenote_clr_link_bg | any | clr_label_bg |
| M.pacenote_clr_link_fg | any | clr_label_fg |
| M.pacenote_clr_cs_to_ce_direct | any | M.clr_grey_light |
| M.pacenote_clr_interlink_txt | any | M.clr_black |
| M.pacenote_linkToWidth | number | 0.25 |
| M.pacenote_linkFromWidth | number | 1.5 |
| M.pacenote_linkHeightRadiusShinkFactor | number | 0.5 |
| M.pacenote_alpha_recce | number | 0.1 |
| M.pacenote_base_alpha_next | number | 0.5 |
| M.pacenote_base_alpha_prev | number | 0.5 |
| M.pacenote_base_alpha_no_sel | number | 0.5 |
| M.pacenote_base_alpha_background | number | 0.5 |
| M.pacenote_shapeAlpha_factor | number | 0.8 |
| M.cam_last_pos_alpha | any | M.snaproads_alpha |
| M.cam_last_pos_radius | any | M.snaproads_radius * 2 |
| M.pacenote_adjacent_radius_factor | number | 0.5 |
| M.recce_cut_clr | any | M.clr_teal |
| M.recce_driveline_clr | any | M.snaproads_clr_recce |
| M.recce_alpha | any | M.snaproads_alpha |
| M.snaproads_alpha_cameraPoint | number | 0.5 |
| M.snaproads_alpha_driving | number | 0.2 |
| M.snaproads_alpha | number | 0.8 |
| M.clr_grey_dark | table | {0.2, 0.2, 0.2} |
| M.clr_grey_light_2 | table | {0.8, 0.8, 0.8} |
| M.clr_grey_light | table | {0.75, 0.75, 0.75} |
| M.clr_grey | table | {0.5, 0.5, 0.5} |
| M.clr_aqua | table | {0.0, 0.8, 0.8} |
| M.clr_pink | table | {1.0, 0.0, 1.0} |
| M.clr_blue_light | table | {0.392,0.612,1} |
| M.clr_blue | table | {0.0, 0.0, 1.0} |
| M.clr_red_pastel | table | {1, 0.494, 0.635} |
| M.clr_light_red | table | {1.0, 0.5, 0.5} |
| M.clr_red_dark | table | {0.5, 0.0, 0.0} |
| M.clr_green_pastel | table | {0.718, 1, 0.455} |
| M.clr_lime_green | table | {0.66, 1.0, 0.0} |
| M.clr_light_green | table | {0.5, 1.0, 0.5} |
| M.clr_green_dark | table | {0.0, 0.5, 0.0} |-|-------------|
| clr_white | {1, 1, 1} | White |
| clr_black | {0, 0, 0} | Black |
| clr_green | {0, 1, 0} | Bright green |
| clr_red | {1, 0, 0} | Bright red |
| clr_teal | {0, 0.76, 0.55} | Primary rally teal |
| clr_teal_2 | {0, 1, 0.58} | Brighter teal variant |
| clr_yellow | {1, 1, 0} | Yellow |
| clr_orange | {1, 0.64, 0} | Orange |
| clr_purple | {0.73, 0, 1} | Purple |
| clr_error | ImVec4(1, 0.2, 0.2, 1) | Error red (ImGui) |
| clr_no_error | ImVec4(0.2, 1, 0.2, 1) | Success green (ImGui) |
Visual Parameters - Snaproads
| Key | Value | Description |
|---|---|---|
snaproads_radius | 0.7 | Default sphere radius |
snaproads_radius_recce | 0.5 | Recce mode radius |
snaproads_radius_driving | 0.2 | Driving mode radius |
snaproads_clr_recce | red | Recce driveline color |
snaproads_clr_route | orange | Route color |
Visual Parameters - Pacenotes
| Key | Value | Description |
|---|---|---|
pacenote_alpha_interlink | 0.5 | Link line opacity |
pacenote_base_alpha_selected | 0.5 | Selected pacenote alpha |
pacenote_alpha_text_selected | 1.0 | Selected text alpha |
pacenote_clr_interlink | pink | Inter-pacenote link color |
Visual Parameters - Waypoints
| Key | Value | Description |
|---|---|---|
waypoint_clr_cs | green | Corner-start color |
waypoint_clr_ce | red | Corner-end color |
waypoint_clr_sphere_hover | white | Hover highlight |
waypoint_shapeAlpha_hover | 0.95 | Hover shape opacity |
How It Works
This is a pure data module - no logic, just constants. Required by virtually all rally editor drawing code:
local cc = require('gameplay/rally/util/colors')
-- Draw a sphere with rally teal
debugDrawer:drawSphere(pos, 1.0, ColorF(cc.clr_teal[1], cc.clr_teal[2], cc.clr_teal[3], 0.8))
-- Use waypoint colors for corner-start/end
local csClr = cc.waypoint_clr_cs -- green
local ceClr = cc.waypoint_clr_ce -- redNotes
- RGB arrays use float range
[0, 1]not[0, 255] - ImGui colors (
ImVec4) are only used forclr_error/clr_no_error - Teal (
clr_teal) is the primary brand color for the rally system
Module Variables
| Variable | Type | Description |
|---|---|---|
M.clr_green_dark | table | {0.0, 0.5, 0.0} |
M.clr_light_green | table | {0.5, 1.0, 0.5} |
M.clr_lime_green | table | {0.66, 1.0, 0.0} |
M.clr_green_pastel | table | {0.718, 1, 0.455} |
M.clr_red_dark | table | {0.5, 0.0, 0.0} |
M.clr_light_red | table | {1.0, 0.5, 0.5} |
M.clr_red_pastel | table | {1, 0.494, 0.635} |
M.clr_blue | table | {0.0, 0.0, 1.0} |
M.clr_blue_light | table | {0.392,0.612,1} |
M.clr_pink | table | {1.0, 0.0, 1.0} |
M.clr_aqua | table | {0.0, 0.8, 0.8} |
M.clr_grey | table | {0.5, 0.5, 0.5} |
M.clr_grey_light | table | {0.75, 0.75, 0.75} |
M.clr_grey_light_2 | table | {0.8, 0.8, 0.8} |
M.clr_grey_dark | table | {0.2, 0.2, 0.2} |
M.snaproads_alpha | number | 0.8 |
M.snaproads_alpha_driving | number | 0.2 |
M.snaproads_alpha_cameraPoint | number | 0.5 |
M.recce_alpha | any | M.snaproads_alpha |
M.recce_driveline_clr | any | M.snaproads_clr_recce |
M.recce_cut_clr | any | M.clr_teal |
M.pacenote_adjacent_radius_factor | number | 0.5 |
M.cam_last_pos_radius | any | M.snaproads_radius * 2 |
M.cam_last_pos_alpha | any | M.snaproads_alpha |
M.pacenote_shapeAlpha_factor | number | 0.8 |
M.pacenote_base_alpha_background | number | 0.5 |
M.pacenote_base_alpha_no_sel | number | 0.5 |
M.pacenote_base_alpha_prev | number | 0.5 |
M.pacenote_base_alpha_next | number | 0.5 |
M.pacenote_alpha_recce | number | 0.1 |
M.pacenote_linkHeightRadiusShinkFactor | number | 0.5 |
M.pacenote_linkFromWidth | number | 1.5 |
M.pacenote_linkToWidth | number | 0.25 |
M.pacenote_clr_interlink_txt | any | M.clr_black |
M.pacenote_clr_cs_to_ce_direct | any | M.clr_grey_light |
M.pacenote_clr_link_fg | any | clr_label_fg |
M.pacenote_clr_link_bg | any | clr_label_bg |
M.waypoint_clr_cs_adjacent | any | M.clr_green_pastel |
M.waypoint_clr_cs_adjacent_bg | any | M.clr_green_dark |
M.waypoint_clr_ce_adjacent | any | M.clr_red_pastel |
M.waypoint_clr_ce_adjacent_bg | any | M.clr_red_dark |
M.waypoint_clr_txt_fg | any | clr_label_fg |
M.waypoint_clr_txt_bg | any | clr_label_bg |
M.waypoint_clr_sphere_selected | any | M.clr_white |
M.waypoint_clr_background | any | M.clr_grey_dark |
M.waypoint_alpha_text_background | number | 0.3 |
M.waypoint_alpha_shape_background | number | 0.3 |
M.waypoint_alpha_selected | number | 0.3 |
M.waypoint_textAlpha_hover | number | 1.0 |
M.waypoint_shapeAlpha_intersectPlane | number | 0.97 |
M.waypoint_planeAlphaFactor | number | 3.2 |
M.new_pacenote_cursor_clr_link | any | M.clr_white |
M.new_pacenote_cursor_clr_cs | any | M.clr_light_green |
M.new_pacenote_cursor_clr_ce | any | M.clr_light_red |
M.new_pacenote_cursor_alpha | number | 0.8 |
M.new_pacenote_cursor_linkHeightRadiusShinkFactor | number | 0.5 |
M.new_pacenote_cursor_linkFromWidth | number | 1.0 |
M.new_pacenote_cursor_linkToWidth | number | 0.25 |
M.clr_error | value | - |
M.clr_green | value | - |
M.clr_no_error | value | - |
M.clr_orange | value | - |
M.clr_purple | value | - |
M.clr_red | value | - |
M.clr_teal_2 | value | - |
M.clr_yellow | value | - |
M.pacenote_alpha_interlink | value | - |
M.pacenote_alpha_text_selected | value | - |
M.pacenote_base_alpha_selected | value | - |
M.pacenote_clr_interlink | value | - |
M.snaproads_clr_route | value | - |
M.snaproads_radius_driving | value | - |
M.snaproads_radius_recce | value | - |
M.waypoint_clr_ce | value | - |
M.waypoint_clr_cs | value | - |
M.waypoint_clr_sphere_hover | value | - |
M.waypoint_shapeAlpha_hover | value | - |
See Also
- Rally JSONL Utilities - Related reference
- Rally Utility Normalizer - Related reference
- Gameplay Systems Guide - Guide
Rally Transcripts Vehicle Snapshot
Lightweight class representing a single vehicle position/rotation snapshot within a transcript. Acts as a data holder for position, quaternion, steering angle, timestamp, and corner call.
Rally JSONL Utilities
Utility module for reading JSON Lines (JSONL) files - line-delimited JSON format used for recce recordings (driveline, cuts, transcripts).