Glitched Scripts
Racing

Localization & items

Locales, distance units, and racing tablet inventory items.

Locales

All user-facing UI / notification strings live in locales/*.json (flat snake_case keys).

Bundled languages

FileLanguage
en.jsonEnglish
es.jsonSpanish
pt.jsonPortuguese (Brazil)
de.jsonGerman
fr.jsonFrench
pl.jsonPolish

Set the active locale:

Config.Locale = 'es' -- en | es | pt | de | fr | pl

Or rely on the ox:locale convar if you use that instead.

To add another language: copy locales/en.jsonlocales/<code>.json, translate values (keep keys and placeholders like %s / [{place}]), then set Config.Locale.

Lua uses ox_lib locale helpers; the tablet UI receives the same dictionary from the resource context.

Control prompts in creator/join text use tokens like {join}, {host}, {place} that resolve to the player's actual keybind labels.

Distance units

Config.DistanceUnit = 'mi' -- or 'km'

Lengths are stored in meters; this only changes labels in the tablet (track length chips, etc.).

Inventory item

Default: racing_tablet — must match Config.TabletItemName.

Framework / inventoryInstall from
QBCore (qb-inventory, qs-inventory, …)items/qbcore.lua
ox_inventoryitems/ox_inventory.lua
ESX (items SQL table)items/esx.sql

items/ is escrow-ignored so you can edit freely. The resource registers the useable hook itself in server/edit.lua for qbcore / qbox / esx.

After adding:

  1. Restart inventory / core
  2. Ensure Config.EnableStandaloneTablet = true
  3. Give the item to a tester

Optional: point the item image at a tablet PNG in your inventory images folder.

On this page