The Lab
VEHICLE native

_GET_TRAIN_DIRECTION_FROM_INDEX

returns BOOL1 parambuild 1207

Returns the direction flag of the train on track trackIndex.

Signature

C
BOOL _GET_TRAIN_DIRECTION_FROM_INDEX(int trackIndex); // 0x67995318F5FAA496 b1207

Parameters

#NameType
1trackIndexint

Facts

Facts about _GET_TRAIN_DIRECTION_FROM_INDEX
Name
_GET_TRAIN_DIRECTION_FROM_INDEX
Hash
0x67995318F5FAA496
Namespace
Returns
BOOL
Game build
1207

Examples

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

Lua
local result = Citizen.InvokeNative(0x67995318F5FAA496, -- _GET_TRAIN_DIRECTION_FROM_INDEX
  0 -- int trackIndex
)
if result then
  -- ...
end
JavaScript
const result = Citizen.invokeNative("0x67995318F5FAA496", // _GET_TRAIN_DIRECTION_FROM_INDEX
  0, // int trackIndex
  Citizen.returnResultAnyway()
);
if (result) {
  // ...
}
C#
bool result = Function.Call<bool>((Hash)0x67995318F5FAA496, // _GET_TRAIN_DIRECTION_FROM_INDEX
  0 // int trackIndex
);
All VEHICLE natives

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