Glitched Scripts
Racing

Installation

Install gs_racing — dependencies, start order, database, and framework.

Follow every step. Most startup errors come from wrong start order, missing deps, or a missing tablet item.

Dependencies (required)

DependencyNotes
ox_libRequired
oxmysqlRequired
Frameworkqb-core, qbx_core (Qbox), or es_extended

Dependencies (optional)

DependencyEnable with
lb-phoneConfig.EnableLBPhone = true
lb-tabletConfig.EnableLBTablet = true
Police dispatch packsConfig.Dispatch (ps / cd / qs / rcore / core / lb-tablet)

Asset order

Start after framework + ox_lib + oxmysql:

ensure ox_lib
ensure oxmysql
ensure qb-core   # or qbx_core / es_extended
ensure gs_racing

Database

On resource start, tables are created automatically from sql/schema.sql (CREATE TABLE IF NOT EXISTS).

TablePurpose
gs_racing_profilesRep, wins, races completed
gs_racing_creatorsWhitelisted track creators
gs_racing_tracksSaved courses
gs_racing_racesHosted / auto / admin races
gs_racing_participantsLobby / race entries
gs_racing_resultsFinishes, times, drift scores
gs_racing_auto_logAuto-event generation log

When Config.AutoImportDefaultRaces = true, sql/tracks.sql imports only if the tracks table is empty.

Framework

-- Detects qbx_core → qb-core → es_extended
Config.Framework = "auto"

-- Or force: "qbcore" | "qbox" | "esx" | "custom"
Config.CustomFrameworkName = false

For "custom", implement the globals in client/edit.lua and server/edit.lua.

Vehicles

Config.Vehicles maps models to racing class + kind. The resource ships with a large GTA V seed list.

  • Add addon cars the same way, or
  • Override ResolveVehicleClass in server/edit.lua

Kinds: CAR, MOTORCYCLE, BOAT, AIRCRAFT — each has its own class ladder (see shared/config).

Tablet item

Copy item defs from items/ (see Localization & items):

InventoryFile
QBCore / qs-inventory etc.items/qbcore.lua
ox_inventoryitems/ox_inventory.lua
ESX items DBitems/esx.sql

Default name: racing_tablet (must match Config.TabletItemName).

  1. Add the item to your inventory
  2. Restart inventory / core (or the server)
  3. Keep Config.EnableStandaloneTablet = true (unless you only use lb-*)
  4. Give the item, e.g. /giveitem [id] racing_tablet 1

Quick config checklist

Config.Framework = "auto"
Config.EnableStandaloneTablet = true
Config.TabletItemName = 'racing_tablet'
Config.TabletCommand = false          -- or 'racingtablet'
Config.AutoImportDefaultRaces = true
Config.Locale = 'en'
Config.DistanceUnit = 'mi'            -- or 'km'

Escrow errors

See FiveM/RedM Asset Escrow.

Next

On this page