Hi, I need to delete the trailer as soon as the player reaches the location, but I can’t. I can uncouple the trailer, but it is no longer possible to delete it. Whats wrong?
0 errors
if IsVehicleAttachedToTrailer(GetVehiclePedIsIn(PlayerPedId())) == 1 then
local trailer = GetVehicleTrailerVehicle(GetVehiclePedIsIn(PlayerPedId()))
DetachVehicleFromTrailer(GetVehiclePedIsIn(PlayerPedId()))
DeleteVehicle(trailer)
end