GetPlayerPing: Difference between revisions

From Multi Theft Auto: Wiki
Jump to navigation Jump to search
No edit summary
 
mNo edit summary
Line 10: Line 10:


==Example==
==Example==
  intPing = [[getPlayerPing]] ( [[findPlayer]] ( Someguy ) )
  intPing = [[getPlayerPing]] ( [[findPlayer]] ( "Someguy" ) )
  [[serverchat]] ( "Someguy's ping is ", intPing, "." )
  [[serverchat]] ( "Someguy's ping is ", intPing, "." )

Revision as of 10:56, 26 March 2006

Description

This function returns the ping (communication time between the client and server) of a specified player.

Syntax

int getPlayerPing ( player player )

Required Arguments

  • player: The player whose ping you want to determine.

Example

intPing = getPlayerPing ( findPlayer ( "Someguy" ) )
serverchat ( "Someguy's ping is ", intPing, "." )