Configuration Guide
Explaining the config
This guide details the configuration settings for the script, compatible as of version 1.1.5. Note that configurations may vary based on your version.
How do I get the coordinates to use in the scripts configuration?
- We suggest using the following resource to obtain coordinates, as it comes already formatted for the configuration pattern: Copy Coords GitHub Repository. The script's usage and commands are detailed in its README.
Framework Settings
- This script supports ESX and QBCore frameworks. Specify your framework in the configuration:
Config.framework = "QBCore" -- [ESX|QBCore] Your framework
If you're using the ESX framework, additional configurations are required:
- Updated ESX Versions: For ESX versions 1.9.0 and newer, set
is_updated
to true. This uses thegetSharedObject
export, replacing the deprecated event system. - Reference: ESX Documentation
- Inventory System: Specify whether your ESX setup uses weight or limit for inventory management.
Config.ESX_settings = { -- (ESX Only) ESX settings
['is_updated'] = true, -- Set to false if your ESX version is older than 1.9.0
['shared_object'] = "esx:getSharedObject", -- GetSharedObject event for who uses an older version than 1.9.0
['esx_version'] = 'weight' -- [weight|limit] Configure here if your inventory uses weight or limit
}
Locale Settings
Configure language translations and currency formats:
- Language: Set the script language. To create a new translation you must go inside the script files and create the files and translate them (there are 2 lang folders in each script).
- Currency and Location: Define your currency format and location to set the correct decimal place formatting.
Config.locale = "en" -- Set the file language [en/br/de/es/fr/zh-cn]
Config.format = {
['currency'] = 'USD', -- This is the currency format, so that your currency symbol appears correctly [Examples: BRL, USD, EUR] (Currency codes: https://taxsummaries.pwc.com/glossary/currency-codes)
['location'] = 'en-US' -- This is the location of your country, to format the decimal places according to your standard [Examples: pt-BR, en-US] (Language codes: http://www.lingoes.net/en/translator/langcode.htm)
}
Script Compatibility
- Here, you can easily switch between the available script compatibilities.
- The "default" option will use the framework's default script.
- If you set it to "other", it's necessary to configure the script inside the custom_scripts folder in the respective file
Config.custom_scripts_compatibility = {
['fuel'] = "default", -- [ox_fuel|ps-fuel|sna-fuel|cdn-fuel|LegacyFuel|default|other] Fuel script Compatibility
['inventory'] = "default", -- [ox_inventory|qs-inventory|ps-inventory|default|other] Inventory script Compatibility
['keys'] = "default", -- [qs-vehiclekeys|cd_garage|jaksam|wasabi_carlock|default|other] Keys script Compatibility
['mdt'] = "default", -- [ps-mdt|redutzu-mdt|default|other] MDT script Compatibility (to log weapon serial)
['target'] = "disabled", -- [qb-target|ox_target|disabled|other] Target script Compatibility (disabled will use markers)
['notification'] = "default", -- [okokNotify|qbcore|default|other] Notification script Compatibility
}
Example for Custom Fuel Script:
- If you set the
['fuel'] = "other"
, then navigate tolc_utils\custom_scripts\client\fuel.lua
and edit the above function adding your export. - Refer to your script documentation to learn about their exports.
function Utils.CustomScripts.setVehicleFuel(vehicle, plate, model, fuel)
-- If you've set the config to "other", you need to configure your export here to set the vehicle fuel.
exports['YOUR_FUEL_EXAMPLE']:SetFuel(vehicle, fuel)
end
For a more detailed guide about configuring your exports, access it here Adding your exports
Vehicle plates
Configure custom plates for job vehicles and player-owned vehicles.
Job Vehicles
- Settings for job vehicles which are spawned by scripts. These vehicles are typically used for tasks such as delivery missions (e.g., trucks for import goods).
- For each script, you have the option to assign a custom license plate prefix. Enter the prefix in the
['plate_prefix']
field. If no prefix is required, leave this field empty:['plate_prefix'] = ""
. - To use a static license plate without generating additional numbers, set
['is_static'] = true
. In this case, the plate prefix will serve as the complete license plate for the vehicle.
Config.spawned_vehicles = { -- Config for the vehicles that are spawned in each script
['lc_truck_logistics'] = { -- The script affected by the config (dont change)
['is_static'] = false, -- false: The plate will be dynamically generated based on the prefix (ex. "TRUCK123"), filling up to 8 characters after the prefix | true: The plate will be exactly as you set in the plate prefix, with no extra numbers added (ex. "TRUCK")
['plate_prefix'] = "TR" -- Customize the prefix for the plate text here (a vehicle plate can hold a max of 8 characters)
},
['lc_stores'] = {
['is_static'] = false,
['plate_prefix'] = "ST"
},
['lc_gas_stations'] = {
['is_static'] = false,
['plate_prefix'] = "GS"
},
... others
}
Player-Owned Vehicles
- This section details the configuration settings for vehicles that players can own, mostly used when buying vehicles in the Dealership script.
- Configure the license plate format and designate the specific garage where the vehicle will be stored.
Config.owned_vehicles = { -- (Only for the vehicles that will be inserted into your garage) This is the config to insert a vehicle in the player owned vehicles table
['plate_format'] = 'xxxxxxxx', -- Plate generation format. [n = number | l = letter | x = any]
['default'] = { -- The garage type
['garage'] = 'motelgarage', -- This is the garage where the owned vehicles will be inserted
['garage_display_name'] = 'Motel Parking' -- Just a nice name to display to the user
},
['airplane'] = {
['garage'] = 'intairport',
['garage_display_name'] = 'Airport Hangar'
},
['boat'] = {
['garage'] = 'lsymc',
['garage_display_name'] = 'LSYMC Boathouse'
}
}