Is it possible to delete cars stacked into each other or bugged I dont how to call it right. But you can not drive that car. Here is pic:
Here is what I tried:
local vehicle = ESX.Game.GetVehicleInDirection()
local playerPed = GetPlayerPed(-1)
local coords = GetEntityCoords(playerPed)
print(vehicle)
SetEntityAsMissionEntity(vehicle, true, true)
DeleteVehicle(vehicle)
ESX.Game.DeleteVehicle(vehicle)
local playerPed = GetPlayerPed(-1)
local coords = GetEntityCoords(playerPed)
print(coords.x)
print(coords.y)
print(coords.z)
ClearAreaOfVehicles(coords.x, coords.y, coords.z, 1000.0, false, false, false, false, false)
I haven’t played with this to much but i think the “ClearAreaOfVehicles” needs to be run in a loop so its running all the time and will keep that are clear of spawning vehilces.
I dont want to clear spawning points of vehicles. I want to despawn/remove/delete spawned cars which are non-driveable. You cant enter them.