RedM Natives

_SET_TRAIN_COLLISION_AVOIDANCE_ENABLED

Enables or disables collision-avoidance behavior for AI-controlled trains.

Hash0xE6BD7DD3FD474415
Runtime nameSetTrainCollisionAvoidanceEnabled
NamespaceVEHICLE
SideClient
NameCommunity guess
Docs
Since build1207

Signature

void _SET_TRAIN_COLLISION_AVOIDANCE_ENABLED(Vehicle train, BOOL toggle);

Parameters

NameTypeDescription
trainVehicle—
toggleBOOL—

Returns void

Description

alloc8or RDR3 NativeDB

Enables or disables collision-avoidance behavior for AI-controlled trains.
When enabled, the train can automatically stop if an obstacle or possible collision is detected ahead on the track. When disabled, it continues moving without reacting to those obstacles.

VORPCORE RDR3natives

Enables or disables collision avoidance behavior for AI-controlled trains.

When enabled, the train will automatically stop if an obstacle or possible
collision is detected ahead on the track. When disabled, the train will
continue moving without reacting to obstacles

Usage

Lua
SetTrainCollisionAvoidanceEnabled(train, toggle)

-- always works, by hash
Citizen.InvokeNative(0xE6BD7DD3FD474415, train, toggle)
JavaScript and C#
JavaScript
SetTrainCollisionAvoidanceEnabled(train, toggle);

// by hash
Citizen.invokeNative('0xE6BD7DD3FD474415', train, toggle);
C#
Function.Call((Hash)0xE6BD7DD3FD474415, train, toggle);
  • The name is a community guess and may change. If the named call is missing in your client build, use InvokeNative with the hash — it always works.

Sources

alloc8or RDR3 NativeDB · VORPCORE RDR3natives

Something wrong or missing? Contribute a verified note — corrections ship through pull requests.