_SET_MISSION_TRAIN_WARP_TO_COORDS
Can be used to rotate the train by setting the BOOL direction
Hash
0xC9EA26893C9E4024Runtime name
SetMissionTrainWarpToCoordsNamespaceVEHICLE
SideClient
NameCommunity guess
Docs
Since build1207
Signature
void _SET_MISSION_TRAIN_WARP_TO_COORDS(Vehicle train, float x, float y, float z, BOOL direction);Parameters
| Name | Type | Description |
|---|---|---|
train | Vehicle | — |
x | float | — |
y | float | — |
z | float | — |
direction | BOOL | — |
Returns void
Description
Notice: BOOL p4 was wrongly named takePassengers (?)
Can be used to rotate the train by setting the BOOL direction
Usage
SetMissionTrainWarpToCoords(train, x, y, z, direction)
-- always works, by hash
Citizen.InvokeNative(0xC9EA26893C9E4024, train, x, y, z, direction)JavaScript and C#
SetMissionTrainWarpToCoords(train, x, y, z, direction);
// by hash
Citizen.invokeNative('0xC9EA26893C9E4024', train, x + 0.0000001, y + 0.0000001, z + 0.0000001, direction);Function.Call((Hash)0xC9EA26893C9E4024, train, x, y, z, direction);- Float parameters: Lua integers (
10, or whole numbers decoded from NUI/JSON) are sent as ints and read as garbage. Write10.0orvalue + 0.0. The generated JS wrappers add0.0000001to non-zero floats for the same reason. - 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
Something wrong or missing? Contribute a verified note — corrections ship through pull requests.