PlayerConnection Interface
Introduction
The PlayerConnection
interface provides information about a player's connection to the server.
Methods
latency
long latency();
Description:
Gets the current latency (ping) of the player.
Returns:
The latency in milliseconds as a long
.
latencyAverage
double latencyAverage();
Description:
Gets the average latency of the player over a period of time.
Returns:
The average latency in milliseconds as a double
.
latencyDeviation
double latencyDeviation();
Description:
Gets the standard deviation of the player's latency.
Returns:
The latency deviation in milliseconds as a double
.