Skip to content

Commit

Permalink
Change GetClosestVehicle native to ESX.Game.GetClosestVehicle
Browse files Browse the repository at this point in the history
  • Loading branch information
bitpredator committed Mar 2, 2024
1 parent b802b8a commit efbdc66
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -483,7 +483,7 @@ AddEventHandler("esx_ambulancejob:putInVehicle", function()
local coords = GetEntityCoords(playerPed)

if IsAnyVehicleNearPoint(coords, 5.0) then
local vehicle = GetClosestVehicle(coords, 5.0, 0, 71)
vehicle = ESX.Game.GetClosestVehicle(coords)

if DoesEntityExist(vehicle) then
local maxSeats, freeSeat = GetVehicleMaxNumberOfPassengers(vehicle)
Expand Down

0 comments on commit efbdc66

Please sign in to comment.