- Documentation
- Server functions
- setTrainDerailable
Function
setTrainDerailable
Stores whether a train can derail (e.g. when taking a bend too fast).
Syntax
bool setTrainDerailable(vehicle element, bool value)Arguments
elementvehicle- The train.
valuebooltrue= can derail.
Returns
true on success.
Example
local train = createVehicle(538, 1700, -1950, 14)
setTrainDerailable(train, false)
Notes
State for scripts. See setTrainDerailed.