GetRandomPlayer

From Multi Theft Auto: Wiki
Revision as of 14:45, 25 April 2007 by Jbeta (talk | contribs)
Jump to navigation Jump to search

This function returns a random player. It is useful for assigning objectives to random players in a Manhunt mode, for example.

Syntax

player getRandomPlayer ( )

Required Arguments

This function has no arguments.

Example

This code outputs a random's player name.

randomPlayer = getRandomPlayer ( )
outputChatBox ( getClientName ( randomPlayer ).." is now the fugitive!" )

See Also