Add seat check

This commit is contained in:
Jérémie N'gadi
2017-08-06 14:35:43 +02:00
parent fbb16673ba
commit be7dc860f5
+1 -1
View File
@@ -18,7 +18,7 @@ AddEventHandler('esx_property:hasEnteredMarker', function(name, part, parking)
local coords = GetEntityCoords(playerPed)
local garage = Config.Garages[name]
if IsPedInAnyVehicle(playerPed, false) then
if IsPedInAnyVehicle(playerPed, false) and GetPedInVehicleSeat(vehicle, -1) == playerPed then
local vehicle, distance = ESX.Game.GetClosestVehicle({
x = coords.x,