mirror of
https://github.com/qbcore-fivem/qb-core.git
synced 2026-09-04 16:23:21 +00:00
chore(styling): ensure consistent indentation & define editorconfig
This commit is contained in:
+7
-3
@@ -46,13 +46,17 @@ end)
|
||||
RegisterNetEvent('QBCore:Command:SpawnVehicle', function(vehName)
|
||||
local ped = PlayerPedId()
|
||||
local hash = GetHashKey(vehName)
|
||||
if not IsModelInCdimage(hash) then return end
|
||||
if not IsModelInCdimage(hash) then
|
||||
return
|
||||
end
|
||||
RequestModel(hash)
|
||||
while not HasModelLoaded(hash) do Wait(10) end
|
||||
while not HasModelLoaded(hash) do
|
||||
Wait(10)
|
||||
end
|
||||
local vehicle = CreateVehicle(hash, GetEntityCoords(ped), GetEntityHeading(ped), true, false)
|
||||
TaskWarpPedIntoVehicle(ped, vehicle, -1)
|
||||
SetModelAsNoLongerNeeded(vehicle)
|
||||
TriggerEvent("vehiclekeys:client:SetOwner", GetVehicleNumberPlateText(vehicle))
|
||||
TriggerEvent("vehiclekeys:client:SetOwner", GetVehicleNumberPlateText(vehicle))
|
||||
end)
|
||||
|
||||
RegisterNetEvent('QBCore:Command:DeleteVehicle', function()
|
||||
|
||||
Reference in New Issue
Block a user