From Liberty Unleashed Wiki
This is called when a player sends a chat message. This event is called even if the player is muted.
- function onPlayerChat( Player player, string message )
- player - The player who spoke
- message - The message the player sent
- 1 - Send the message to other clients, unless they're muted
- 0 - Returning 0 will cancel this message and effectively mute the player
This example checks if the player has been muted, and if they are, sends a message to them stating they have been muted.
- function onPlayerChat( player, text )
- if ( player.Muted )
- MessagePlayer( "You are currently muted.", player );
- return 1;