Is there a way to get all vehicle entity “ids” in the server and smash them into a table?
1 Like
function GetAllVehicles()
local ret = {}
for veh in EnumerateVehicles() do
table.insert(ret, veh)
end
return ret
end
Note: This will only get you vehicles near the current client. You will need to call this on every client if you want to get every vehicle in the server.