Closed bgibson6828 closed 2 years ago
This is a issue with the Radial Menu to apply the vehicle. When using a external ExtraMenu BEFORE using Radial, it works as intended.
Having a similar issue, mine doesn't show up at all.
The error keeps popping up. If you change the code for the previous one, it works fine.
RegisterNetEvent('qb-radialmenu:client:setExtra') AddEventHandler('qb-radialmenu:client:setExtra', function(data) local string = data.id local replace = string:gsub("extra", "") local extra = tonumber(replace) local ped = PlayerPedId() local veh = GetVehiclePedIsIn(ped) local enginehealth = 1000.0 local bodydamage = 1000.0
if veh ~= nil then
local plate = GetVehicleNumberPlateText(closestVehicle)
if GetPedInVehicleSeat(veh, -1) == PlayerPedId() then
if DoesExtraExist(veh, extra) then
if IsVehicleExtraTurnedOn(veh, extra) then
enginehealth = GetVehicleEngineHealth(veh)
bodydamage = GetVehicleBodyHealth(veh)
SetVehicleExtra(veh, extra, 1)
SetVehicleEngineHealth(veh, enginehealth)
SetVehicleBodyHealth(veh, bodydamage)
QBCore.Functions.Notify('Extra ' .. extra .. ' Desactivado', 'error', 2500)
else
enginehealth = GetVehicleEngineHealth(veh)
bodydamage = GetVehicleBodyHealth(veh)
SetVehicleExtra(veh, extra, 0)
SetVehicleEngineHealth(veh, enginehealth)
SetVehicleBodyHealth(veh, bodydamage)
QBCore.Functions.Notify('Extra ' .. extra .. ' Activado', 'success', 2500)
end
else
QBCore.Functions.Notify('Extra ' .. extra .. ' no está presente en este vehículo ', 'error', 2500)
end
else
QBCore.Functions.Notify('¡No eres conductor de un vehículo!', 'error', 2500)
end
end
end)
Does anyone have a specific vehicle and extra they tried that I can test it with?
Does anyone have a specific vehicle and extra they tried that I can test it with?
I know for certain it was doing it on the OCRP Law Enforcement Pack 110%, but I didnt use many other modded vehicles at the time.
I don't have any addon cars, test some gta cars
They work fine for me
it seems to only be an issue with addon vehicles.
wouldnt it be smarter to just add Vehicle Extras to choose at bennys so that they also get actually saved into the DB?
No, if it's an issue with addon vehicles, it means that something is wrong in either the carcols or carvariations meta files
do you guys have any fix yet? i still need to /fix the vehicle for the extras to show up onto the car
I got this bug aswell with this truck. https://lunardev.co.uk/products/benefactor-recovery-truck
The ramps are extras 5 but i can only use it 1 time to show or hide, doing it again wont show nor remove again
When placing a vehicle extra onto a car you have to /fix the vehicle for the extras to show up onto the car