βοΈ Configuration
Complete configuration guide for BIT-Drivingschool.
Framework Configuration
-- Use "esx" or "qb"
Config.Framework = "qb"
-- If you are using one of the most recent versions of ESX, set the script name. Default = "es_extended"
Config.ESXExport = ""
-- Default ESX: "esx:getSharedObject" | Default QB: "qb-core"
Config.Core = "qb-core"
-- oxmysql, mysql-async or ghmattisql
Config.Mysql = "oxmysql"
License Prices
-- A license price (Motorcycle)
Config.licenseAprice = 2500
-- B license price (Car)
Config.licenseBprice = 5500
-- C license price (Truck)
Config.licenseCprice = 10000
Speed Configuration
-- Set true if you want use KMH or false if you want to use MPH
Config.useKMH = true
-- Maximum highway speed
Config.highwaySpeed = 120
-- Maximum speed in the city
Config.urbanSpeed = 60
-- Maximum speed in interurban areas
Config.interUrbanSpeed = 90
Test Configuration
-- Number of questions for the theoretical test
Config.theoricalTotalQuestions = 9
-- Answers needed to pass the theory test
Config.correctAnswersNeeded = 5
-- Maximum number of errors that can be made in the practical test
Config.MaxErrorsPractice = 5
-- Set to true if you want users to have to repeat the theory for each license
Config.repeatTheorical = false
License Names
-- Motorcycle license name in the database
Config.licenseNameMoto = 'moto'
-- Car license name in the database
Config.licenseNameCar = 'driver'
-- Truck license name in the database
Config.licenseNameTruck = 'truck'
TTS Language
-- Instructor audio language
-- EN -> English / FR -> French / DE -> German / ES -> Spanish / HUN -> Hungarian
Config.TTSLanguage = 'EN'
Additional Settings
-- Font used in alerts. Set to 0 if your language is Chinese
Config.alertTextFont = 4
-- Set to true if you want to use ESX.DeleteVehicle or QBCore.Functions.DeleteVehicle
Config.UseEsxQBDeleteVehicle = false
-- Check license in the database
Config.checkDBLicense = true
-- Teleport the user to the driving school if he fails the practical test
Config.teleportIfFails = true
-- Coordinates to teleport the user if fails the practical test
Config.teleportIfFailsCoord = vector3(222.42, -1393.44, 30.59)
-- Check if there is a vehicle at spawn point
Config.checkspawnpoint = true
-- Account to which you want the money to be charged
Config.accountToRemoveMoney = "bank"
Keys System
Config.useKeys = true
function addKeys(vehicle)
-- Insert here your trigger. EX:
-- TriggerServerEvent("keyscar:server:addKey", GetVehicleNumberPlateText(vehicle), false)
end
function removeKeys(vehicle, plate)
if vehicle ~= 0 and plate ~= nil then
-- Insert here your trigger
end
end
Fuel System
-- set to true if you want to use a custom fuel script
Config.useCustomFuel = false
function setFuel(vehicle)
-- Insert your custom fuel trigger here
end
Vehicles
Vehicles.moto = 'double'
Vehicles.car = 'blista'
Vehicles.truck = 'phantom'
Vehicles.spawn = {
x = 224.92,
y = -1379.05,
z = 30.54,
heading = 204.09
}
NPCs Configuration
Receptionist
Receptionist.npc = 'cs_jewelass'
Receptionist.x = 214.45
Receptionist.y = -1400.163
Receptionist.z = 29.57
Receptionist.heading = 317.48
Practice Instructor
PracticeInstructor.use = true
PracticeInstructor.npc = 'csb_trafficwarden'
PracticeInstructor.x = 219.95
PracticeInstructor.y = -1398.27
PracticeInstructor.z = 30.20
PracticeInstructor.heading = 334.48
-- if you want the npc to spawn directly inside the vehicle
PracticeInstructor.useTeleport = false
Theorical Instructor
TheoricalInstructor.npc = 'csb_reporter'
TheoricalInstructor.x = 208.69
TheoricalInstructor.y = -1382.96
TheoricalInstructor.z = 29.57
TheoricalInstructor.heading = 130.39
Theorical User Position
TheoricalUserPosition.x = 207.40
TheoricalUserPosition.y = -1384.23
TheoricalUserPosition.z = 29.57
TheoricalUserPosition.heading = 314.64
Notifications
function notifications(notitype, message, time)
-- Change this trigger for your notification system keeping the variables
TriggerEvent('codem-notification', message, time, notitype)
end
-- Notifications types:
Noti.info = 'info'
Noti.check = 'check'
Noti.error = 'error'
-- Notification time:
Noti.time = 5000
Blips
Blips.active = true
Blips.coord = {
x = 214.45,
y = -1400.163,
z = 30.57
}
Blips.blip = 227
Blips.blipColor = 2
Blips.blipScale = 0.9
Blips.blipText = "Driver School"
Markers
Marker = {
x = 214.45,
y = -1400.163,
z = 30.57,
mtype = 23,
-- RGB COLOR:
r = 245,
g = 14,
b = 70,
-- DISTANCE AND SIZE:
dis = 3,
size = 2.0
}
Target System
Config.useTarget = true
function entityTarget(entity, event)
exports['qb-target']:AddTargetEntity(entity, {
options = {{
type = "client",
event = event,
icon = "fas fa-box-circle-check",
label = Lang.open
}},
distance = 3.0
})
end
Language
Lang.theoricalneeded = "You must take the theoretical test before taking the practical test"
Lang.returnvehicule = "Return to the vehicle. The test will be cancelled in 10 seconds"
Lang.testcanceled = "The test has been cancelled. Retest again"
Lang.approved = "Congratulations, you have passed!"
Lang.suspended = "You have failed, you can try again another time."
Lang.passed = "You have already passed this test, you cannot take it again"
Lang.enter = "Press ~r~E~w~ to access the ~g~driving school"
Lang.deletedLicense = "The license has been successfully removed"
Lang.noMoney = "You don't have enough money"
Lang.occupiedSpace = "The space to take the vehicle out of the driving school is occupied"
Lang.open = "Access the driving school"
Triggers
Open Menu
TriggerClientEvent("bit-driverschool:openMenu")
Delete License
TriggerServerEvent("bit-driverschool:deleteLicense", playerID, license)