Hide chat commands
Hi, i used this code for hide all chat commands like a /hp , /top15 etc.
PHP Code:
register_clcmd( "say", "cmdCheckCmd" ) register_clcmd( "say_team", "cmdCheckCmd" )
public cmdCheckCmd( id ) { new szSaid[ 128 ] read_args( szSaid, sizeof szSaid -1 ) remove_quotes( szSaid ) if( szSaid[ 0 ] == '/' || equal( szSaid, "command" ) ) { return PLUGIN_HANDLED_MAIN } return PLUGIN_CONTINUE }
All works fine and all players cant see all commands, but ... If player havent team (spectate), he see all commands and this script doesnt hide.
Why?
|