mirror of
https://github.com/qbcore-fivem/qb-core.git
synced 2026-08-28 17:01:16 +00:00
Framework Optimization
for optimization of other resources.
This commit is contained in:
@@ -117,6 +117,18 @@ RegisterNetEvent('QBCore:Command:GoToMarker', function()
|
||||
end)
|
||||
|
||||
-- Vehicle Commands
|
||||
RegisterNetEvent('QBCore:Client:VehicleInfo', function(info)
|
||||
local data = {
|
||||
vehicle = NetToVeh(info.netid),
|
||||
seat = info.seat,
|
||||
name = info.modelName,
|
||||
plate = QBCore.Functions.GetPlate(info.vehicle),
|
||||
driver = GetPedInVehicleSeat(info.vehicle, -1),
|
||||
inseat = GetPedInVehicleSeat(info.vehicle, info.seat),
|
||||
haskeys = exports['qb-vehiclekeys']:HasKeys(plate)
|
||||
}
|
||||
TriggerEvent('QBCore:Client:'..info.event..'Vehicle', data)
|
||||
end)
|
||||
|
||||
RegisterNetEvent('QBCore:Command:SpawnVehicle', function(vehName)
|
||||
local ped = PlayerPedId()
|
||||
|
||||
Reference in New Issue
Block a user