SetPlayerMuted

From Multi Theft Auto: Wiki
Revision as of 18:20, 7 December 2008 by Awwu (talk | contribs)
Jump to navigation Jump to search

Use this function to mute or unmute the player.

Syntax

bool setPlayerMuted ( player thePlayer, bool state )

Required Arguments

  • thePlayer: The player you are muting or unmuting.
  • state: Use true to mute and false to unmute the player.

Returns

Returns true if the player was successfully muted or unmuted, false otherwise.

Example

someguy = getPlayerFromNick ( "someGuy" )
if ( not isPlayerMuted ( someguy ) ) then
   setPlayerMuted ( someguy, true )
   outputChatBox ( "You just got muted.", someguy )
end

See Also