IsPlayerMuted: Difference between revisions

From Multi Theft Auto: Wiki
Jump to navigation Jump to search
No edit summary
No edit summary
Line 1: Line 1:
__NOTOC__
__NOTOC__
{{Server client function}}
{{Server client function}}
This function returns true if a player has been muted and false otherwise.
Use this function to check if a player has been muted.


==Syntax==
==Syntax==
Line 7: Line 7:


===Required Arguments===
===Required Arguments===
*'''player''': The [[player]] you are checking.
*'''thePlayer:''' The [[player]] you are checking.


===Returns===
===Returns===
Returns true if a player has been muted and false otherwise.
Returns ''true'' if the player is muted and ''false'' otherwise.


==Example==
==Example==
<syntaxhighlight lang="lua">if ( isPlayerMuted ( findPlayer ( "someGuy" ) ) then
<syntaxhighlight lang="lua">
   outputChatBox ( "It seems Someguy can't speak to you.", player )
someguy = getPlayerFromNick ( "someGuy" )
end</syntaxhighlight>
if ( isPlayerMuted ( someguy ) then
   outputChatBox ( "It seems Someguy can't speak." )
end</syntaxhighlight>


==See Also==
==See Also==
{{Player functions}}
{{Player functions}}

Revision as of 20:07, 16 August 2007

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 = getPlayerFromNick ( "someGuy" )
if ( isPlayerMuted ( someguy ) then
   outputChatBox ( "It seems Someguy can't speak." )
end

See Also