Skip to main content

Themes & Locale

Theme definitions and locale system

This section

Themes & Locale

Per-player UI themes and all user-facing strings.

Themes

4 built-in themes are defined in Config.Themes. Each theme has:

FieldDescription
idUnique theme identifier
imageBackground image filename (in ui/images/backgrounds/)
color1Primary background color
color2Accent color
color3Secondary background color
borderBorder color
menuMenu background color
menuActiveActive menu item color

Built-in Themes

IDDescription
grayDefault dark theme
blueBlue accent theme
redRed accent theme
yellowYellow/gold accent theme

Adding Custom Themes

Add new entries to Config.Themes:

lua
{
id = "purple",
image = "5.png",
color1 = "rgba(80, 0, 120, 0.60)",
color2 = "rgba(150, 0, 255, 0.35)",
color3 = "rgba(80, 0, 120, 0.60)",
border = "#9600FF",
menu = "#3D0066",
menuActive = "#9600FF",
}

Locale System

All UI text is defined in Config.Language. The language table is sent to the React UI and consumed by the LanguageProvider.

String Categories

  • Menu Labels: home, settings, vehicleControl, musicPlayer, navigation
  • Vehicle Controls: engine, leftDoor, rightDoor, hood, trunk, lock, unlocked, locked, doorDance
  • Window Labels: leftWindow, rightWindow, backLeftWindow, backRightWindow
  • AutoPilot: ecoMode, sportMode, sportPlusMode, autoPilotStart, selectLocationOnMap, arrivedAttheLocation
  • Light Control: headlight, frontNeon, backNeon, leftNeon, rightNeon, neonRgb, neonBring, headlightRgb, headlightBring
  • Weather: sunny, clear, rainy, snowy, foggy, cloudy, PartlyCloudy
  • Music: musicPlayer, quickPlayer, enterYoutubeUrl, library, allMusic, playLists, liked, likedMusics, likedSongs, noSong
  • Settings: setaTheme, used, navigation, navigationPosition, setaPosition, confirm, cancel