onPlayerEnteredTrain
From Liberty Unleashed Wiki
This is called when a player has successfully entered a train.
Syntax
function onPlayerEnteredTrain( Player player, int train )
Arguments
- player - The player who entered a train
- train - The ID of the train the player entered. NOTE: This argument was added in update 0.1.0.11, so it is not present in previous versions
Returns
This event does not handle return values.
Example
This example will message a player when they enter a train.
function onPlayerEnteredTrain( player, train ) { MessagePlayer( "You entered a train.", player ); return 1; }
Notes
The function MessagePlayer was used in this example. More info about it can be found in the corresponding page.