diff --git a/client/main.lua b/client/main.lua index 2a5b1952..91dc3fc2 100644 --- a/client/main.lua +++ b/client/main.lua @@ -1018,27 +1018,27 @@ Citizen.CreateThread(function() local vehicleProps = ESX.Game.GetVehicleProperties(CurrentActionData.vehicle) TriggerServerEvent('esx_society:putVehicleInGarage', 'mecano', vehicleProps) - else - - if - GetEntityModel(vehicle) == GetHashKey('flatbed') or - GetEntityModel(vehicle) == GetHashKey('towtruck2') or - GetEntityModel(vehicle) == GetHashKey('slamvan3') - then - TriggerServerEvent('esx_service:disableService', 'mecano') - end + else + if + GetEntityModel(vehicle) == GetHashKey('flatbed') or + GetEntityModel(vehicle) == GetHashKey('towtruck2') or + GetEntityModel(vehicle) == GetHashKey('slamvan3') + then + TriggerServerEvent('esx_service:disableService', 'mecano') end - ESX.Game.DeleteVehicle(CurrentActionData.vehicle) end + ESX.Game.DeleteVehicle(CurrentActionData.vehicle) + elseif CurrentAction == 'remove_entity' then DeleteEntity(CurrentActionData.entity) end CurrentAction = nil end + end if IsControlJustReleased(0, Keys['F6']) and not IsDead and PlayerData.job ~= nil and PlayerData.job.name == 'mecano' then OpenMobileMecanoActionsMenu()