Frameworks and Config.Bridge
Vision, ESX, QBCore, Qbox or standalone: automatic detection and the common options of the Config.Bridge block.
#Supported frameworks
| Framework | Detected resource | Player identifier |
|---|---|---|
| Vision | core | core identifier |
| Qbox | qbx_core | citizenid |
| QBCore | qb-core | citizenid |
| ESX | es_extended | identifier |
| Standalone | none | Rockstar license |
Detection follows this order: Vision → Qbox → QBCore → ESX → standalone. It happens when the script loads, so start your framework first.
All compatibility code lives in each script's bridge/ folder (in clear text). The rest of the script only calls Bridge.* functions, so you can adapt a specific behaviour without touching the encrypted logic.
#The Config.Bridge block
You will find it in every script's config.lua. Default values suit the vast majority of servers.
Config.Bridge = {
Framework = 'auto', -- 'auto' | 'vision' | 'qbox' | 'qbcore' | 'esx' | 'standalone'
Inventory = 'auto', -- 'auto' | 'ox_inventory' | 'qs-inventory' | 'qb-inventory' | 'framework' | 'none'
Target = 'auto', -- 'auto' | 'ox_target' | 'qb-target' | 'none'
Society = 'auto', -- society account (depends on the script)
Callbacks = 'auto', -- 'auto' | 'native'
Debug = false, -- detection logs in the console
Admins = {}, -- identifiers always treated as staff, e.g. { 'license:xxxx' }
AdminAce = 'command', -- ACE permission granting staff access (outside Vision)
Standalone = {}, -- functions to provide in standalone mode
}| Option | Role |
|---|---|
Framework | auto detects it for you. Force a value only if detection is wrong. |
Inventory | Inventory used for items and chests. |
Target | Target system. Without one, the script shows a marker and waits for the E key. |
Society | Society account to cash in (tc-mechanic): vision, renewed, qb-banking, okok, esx_society, qbx, internal. |
Callbacks | auto: ox_lib, then framework callbacks, then built-in callbacks. |
Debug | Prints what was detected in the server console. |
Admins | Identifiers treated as staff on top of ACE and framework groups. |
AdminAce | ACE permission checked for staff (outside Vision). |
Standalone | Table of functions to provide when you have no framework. |
#Standalone mode
Without a framework, each script needs a few functions from you in Config.Bridge.Standalone. Details are on each script's Configuration page; the principle is:
Config.Bridge.Standalone = {
getJob = function(src)
-- you tell the script what the player's job is
return { name = 'police', label = 'Police', grade = 2, gradeName = 'sergeant', onDuty = true }
end,
}| Script | Expected functions |
|---|---|
| tc-mechanic | getJob, getMoney, removeMoney / addMoney, vehicleRow, saveVehicleProps, createInvoice |
| tc-divisions | getJob, listJobs, and getMoney / removeMoney / addMoney / itemCount / addItem for paid shops |
| tc-forensic | getJob, getCharacter, itemCount, addItem, removeItem |
| tc-contextmenu | getJob |
| tc-banana_defuse | none |
On Vision, scripts behave as designed with the core: managed interaction points, /gestion panel permissions, core invoices and society account.