The settings every TR script shares, in tr_core/config.lua and server_config.lua.
On this page
tr_core's settings are in two files. Every TR script uses them. Restart the server after a change.
File
What's in it
config.lua
The language, the console output, and which of your scripts tr_core works with
server_config.lua
The Discord webhooks. Only the server reads this file; it is never sent to players' games
Everything is on auto, so most servers change nothing.
config.lua
config.lua
-- tr_core settings, shared by every TR script. Restart the server after a change.-- Discord webhooks go in server_config.lua: this file is sent to every player's game.return { locale = 'en', -- the language: a file in each script's locales/ folder ('en', 'sv', ...) logLevel = 'info', -- what prints in the console: 'error', 'warn', 'info' or 'debug' -- The scripts tr_core works with. 'auto' finds them by itself. framework = 'auto', -- 'esx', 'qb', 'qbx' inventory = 'auto', -- 'ox_inventory', 'qb_inventory' target = 'auto', -- 'ox_target', 'qb_target', or 'tr_core' for its own (a dot, then E) keys = 'auto', -- your vehicle keys script, or 'none' fuel = 'auto', -- your fuel script, or 'none' dispatch = 'auto', -- your police dispatch script, or 'none' -- Your framework's money types. 'auto' uses its usual ones. accounts = { cash = 'auto', bank = 'auto', dirty = 'auto', -- QBCore and Qbox have none: put yours here, or dirty money reads as 0 },}
General
Setting
Default
What it does
locale
'en'
The language of every TR script. Each script keeps its text in its own locales folder; add a file there to translate it
logLevel
'info'
What TR scripts print in the console: 'error', 'warn', 'info' or 'debug'. Use 'debug' when support asks for it
Your scripts
tr_core finds your framework, inventory and the rest by itself ('auto'). Where a kind has several, the first one that's running is used. Set one yourself when you run something it doesn't pick, or two of a kind.
The resource's own name works too ('es_extended', 'qb-target').
target is how players pick an option on a player, a car or a thing (Breath test on a player, for example). On 'auto' that's ox_target or qb-target when your server has one. Without either, or with 'tr_core', it's tr_core's own: a dot on what can be used, and E to pick.
Money accounts
Setting
Default
What it does
accounts.cash
'auto'
The framework money type TR scripts use for cash
accounts.bank
'auto'
The same for the bank
accounts.dirty
'auto'
The same for dirty money. ESX has one (black_money). QBCore and Qbox have none: set yours here, or dirty money reads as 0
'auto' uses the framework's usual one.
server_config.lua
server_config.lua
-- tr_core settings only the server sees: this file is never sent to players' games, so secrets go here.return { -- Discord webhooks for TR scripts' logs. Each log names its channel at the bottom ('security', 'money', ...). webhooks = { default = '', -- every log -- security = '', -- a channel with its own webhook },}
Setting
Default
What it does
webhooks.default
''
The Discord webhook TR scripts send their logs to
webhooks.<channel>
A channel with its own webhook. Every log names its channel at the bottom (for example security or money)
From tr_core 1.4.0, logs for one webhook go out together, up to 10 in a message, so Discord never turns them away. A player who sets off many security logs in a row gives one log, then a summary of the rest a minute later.