IsPlayerMuted: Difference between revisions

From Multi Theft Auto: Wiki
Jump to navigation Jump to search
mNo edit summary
No edit summary
Line 14: Line 14:
==Example==
==Example==
<syntaxhighlight lang="lua">
<syntaxhighlight lang="lua">
someguy = getPlayerFromNick ( "someGuy" )
someguy = getPlayerFromName ( "someGuy" )
if isPlayerMuted ( someguy ) then
if isPlayerMuted ( someguy ) then
   outputChatBox ( "It seems Someguy can't speak." )
   outputChatBox ( "It seems Someguy can't speak." )

Revision as of 16:14, 22 November 2011

Use this function to check if a player has been muted.

Syntax

bool isPlayerMuted ( player thePlayer )

Required Arguments

  • thePlayer: The player you are checking.

Returns

Returns true if the player is muted and false otherwise.

Example

someguy = getPlayerFromName ( "someGuy" )
if isPlayerMuted ( someguy ) then
   outputChatBox ( "It seems Someguy can't speak." )
end

See Also