GetPlayerArrival
The region a player came from on a trip, and the data sent with them.
Holds from their join on, so OnPlayerConnect can read it - say, to let a player who was logged in there stay logged in. The data comes in a
signed pass, so a player can read it but not change it. nil for anyone who did not come on a trip.
Syntax
Section titled “Syntax”GetPlayerArrival(pid)| Parameter | Type | |
|---|---|---|
pid |
number | the player |
Returns
Section titled “Returns”string, string - the region and the data, or nil
Example
Section titled “Example”function OnPlayerConnect(pid) local from, data = GetPlayerArrival(pid) if from and data == "logged" then loadCharacter(pid) else askPassword(pid) endendSee also
Section titled “See also”OnPlayerArrive · OnPlayerTravel · SendPlayerToRegion · the Regions group of the index
