ACP QBCore
Logs
Vehicles Logs

Insert Vehicle

With the help of this function, you add vehicles to players profiles. So you can see what vehicles he owns when you enter his profile

local vehData = {
    vehicle = 'adder',
    name = 'adder' or 'Adder Super Sport',
    carPlate = 'LS232323',
}
 
exports['syn-acp']:insertVehicle(citizenid, vehData)

Insert Vehicle - Parameters Description

citizenid => Parameter Description:
The unique identifier for the curerent housw owner


Update Vehicle Owner

This function helps you update the vehicles on the players' profiles when a transaction between players occurs

local newOwner = 1     -- New Owner Citizen ID
local oldOWner = 2     -- Old Owner Citizen ID
local vehicle = 'adder'      -- Vehicle ID
 
exports['syn-acp']:updateVehicle(vehicle, oldOWner, newOwner)

Update Vehicle - Parameters Description

vehicle => Parameter Description:
The unique identifier or spawncode (how you want) for the vehicle.

newOwner => Parameter Description:
The unique identifier for the new vehicle owner.

oldOWner => Parameter Description:
The unique identifier for the old vehicle owner.


Remove User Vehicle

This function helps you delete a vehicle from a player's profile.

exports['syn-acp']:removeVehicle(citizenid, 'adder')

Remove Vehicle - Parameters Description

vehicle => Parameter Description:
The unique identifier or spawncode (how you want) for the vehicle.

citizenid => Parameter Description:
The unique identifier for the curerent vehicle owner