qb-core

To install MrNewbVehicleKeys to the core you will need use this snippet

Step #1 adding RemoveKeys for /dv, find the below in qb-core/client/events.lua
-- Find This in qb-core/client/events.lua aprox around line 144
RegisterNetEvent('QBCore:Command:DeleteVehicle', function()
    local ped = PlayerPedId()
    local veh = GetVehiclePedIsUsing(ped)
    if veh ~= 0 then
        SetEntityAsMissionEntity(veh, true, true)
        DeleteVehicle(veh)
    else
        local pcoords = GetEntityCoords(ped)
        local vehicles = GetGamePool('CVehicle')
        for _, v in pairs(vehicles) do
            if #(pcoords - GetEntityCoords(v)) <= 5.0 then
                SetEntityAsMissionEntity(v, true, true)
                DeleteVehicle(v)
            end
        end
    end
end)

Please note, if you are using an alternative admin menu that registers the command /car you will need to add my exports there as well. Default qb-vehiclekeys events should all work as of now.

Last updated