_DETERMINE_VEHICLE_COMPARTMENT_STATE
Determines the interaction/storage state of a vehicle rear compartment or storage area.
0x877EA24EB1614495DetermineVehicleCompartmentStateSignature
BOOL _DETERMINE_VEHICLE_COMPARTMENT_STATE(Any* outState, Vehicle vehicle, Ped ped);Parameters
| Name | Type | Description |
|---|---|---|
outState | Any* | — |
vehicle | Vehicle | — |
ped | Ped | — |
Returns BOOL
Description
Determines the interaction/storage state of a vehicle rear compartment or storage area.
Returns whether the query succeeded and writes a state value to outState.
Observed states:
- 1 = compartment available / unopened
- 57 = vehicle has no valid compartment/storage
- 72 = compartment opened, resolved or depleted
Used by wagons with rear storage and prison wagons with breakable locks.
Determines the interaction/storage state of a vehicle rear compartment or storage area.
Returns whether the query was successful and writes a state value to outState
Observed states:
* 1 = Compartment available / unopened
* 57 = Vehicle has no valid compartment/storage
* 72 = Compartment opened, resolved or depleted
Usage
local retval, outState = DetermineVehicleCompartmentState(vehicle, ped)
-- always works, by hash
local retval, outState = Citizen.InvokeNative(0x877EA24EB1614495, Citizen.PointerValueInt(), vehicle, ped, Citizen.ReturnResultAnyway())JavaScript and C#
const [retval, outState] = DetermineVehicleCompartmentState(vehicle, ped);
// by hash
const [retval, outState] = Citizen.invokeNative('0x877EA24EB1614495', Citizen.pointerValueInt(), vehicle, ped, Citizen.returnResultAnyway());var outState = new OutputArgument();
bool retval = Function.Call<bool>((Hash)0x877EA24EB1614495, outState, vehicle, ped);
// outState.GetResult<int>()- Pointer (out) arguments are not passed in Lua/JS: their values are returned after the result, in order.
Any*arguments are often structs. Build them with a DataView buffer and pass it with:Buffer()— see the examples and notes below.- The name is a community guess and may change. If the named call is missing in your client build, use
InvokeNativewith the hash — it always works.
Sources
alloc8or RDR3 NativeDB · VORPCORE RDR3natives
Something wrong or missing? Contribute a verified note — corrections ship through pull requests.