The Lab
PED native

GET_VEHICLE_PED_IS_IN

returns Vehicle2 paramsbuild 1207

Returns the vehicle ped is in; with lastVehicle true it returns the last vehicle used.

Signature

C
Vehicle GET_VEHICLE_PED_IS_IN(Ped ped, BOOL lastVehicle); // 0x9A9112A0FE9A4713 b1207

Parameters

#NameType
1pedPed
2lastVehicleBOOL

Facts

Facts about GET_VEHICLE_PED_IS_IN
Name
GET_VEHICLE_PED_IS_IN
Hash
0x9A9112A0FE9A4713
Namespace
Returns
Vehicle
Game build
1207

Examples

Calls by hash work in every RedM runtime. Replace the placeholder arguments with your own values.

Lua
local vehicle = Citizen.InvokeNative(0x9A9112A0FE9A4713, -- GET_VEHICLE_PED_IS_IN
  PlayerPedId(), -- Ped ped
  false, -- BOOL lastVehicle
  Citizen.ResultAsInteger()
)
print(vehicle)
JavaScript
const vehicle = Citizen.invokeNative("0x9A9112A0FE9A4713", // GET_VEHICLE_PED_IS_IN
  PlayerPedId(), // Ped ped
  false, // BOOL lastVehicle
  Citizen.resultAsInteger()
);
console.log(vehicle)
C#
int vehicle = Function.Call<int>((Hash)0x9A9112A0FE9A4713, // GET_VEHICLE_PED_IS_IN
  API.PlayerPedId(), // Ped ped
  false // BOOL lastVehicle
);
All PED natives

Facts compiled from community research (alloc8or/rdr3-nativedb-data, femga/rdr3_discoveries); descriptions and examples by The Lab.