Configuration
Below we have explained some of the key features found in our Config file within the Vehicle Insurance Script.
Framework
Inventory
Target System
Location
Insurance Prices
Direct Debit
Using qs-inventory
Items also need to be added to the qb-core -> shared -> items.lua to ensure for compatibility with qs-inventory.
Using ox_intentory
Using qb-core
Config File before edits
Config = {}
Config.Framework = 'qbcore' -- 'qbcore', 'qbox'
Config.InventorySystem = 'qs' --'qb' = [qb-inventory], 'ox' = [ox_inventory], 'qs' = [qs-inventory]
Config.Currency = '£' -- Currency symbol for the insurance prices
Config.ViewPolicy_distance = 3.0 -- (METERS) This is the distance needed to be able to see the Insurance Policy UI when the item has been used by a player
Config.InsuranceLocation = {
coords = vector4(234.49, 226.13, 106.29, 246.05), --vector4(243.63, 226.25, 106.29, 157.3)
blipSprite = 606,
blipColor = 3,
blipScale = 0.8,
blipLabel = "Vehicle Insurance"
}
Config.Target = 'auto' -- 'qb-target', 'ox_target', or 'auto' for auto-detection
Config.InsurancePrices = {
compacts = 500,
sedans = 750,
suvs = 1000,
coupes = 850,
muscle = 1200,
sportsclassics = 1500,
sports = 2000,
super = 3000,
motorcycles = 400,
offroad = 900,
industrial = 800,
utility = 600,
vans = 700,
cycles = 50,
boats = 2500,
helicopters = 5000,
planes = 7500,
service = 600,
emergency = 1000,
military = 2000,
commercial = 1500,
trains = 10000
}
Config.DirectDebit = {
enabled = true,
intervalDays = 7, -- Payment every 30 days
APR = 0.239,
lateFeePenalty = 0.1 -- 10% penalty for late payments
}
Config.InsurancePed = {
model = 'a_m_m_prolhost_01',
scenario = 'WORLD_HUMAN_CLIPBOARD'
}Last updated