AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   Scripting Help (https://forums.alliedmods.net/forumdisplay.php?f=11)
-   -   [HELP] block commands console (https://forums.alliedmods.net/showthread.php?t=215595)

joyceteamo 05-09-2013 22:09

[HELP] block commands console
 
can someone edit this plugin to block also commands in the console such as ex: fps_max, fps_override, kill, etc.

PHP Code:

#include < amxmodx >
#include < cstrike >

public plugin_init( )
{
    
register_plugin"Block jointeam""0.1""Exolent" );
}

public 
client_commandclient )
{
    static const 
szJoinCommand[ ] = "jointeam";
    
    static 
szCommand10 ];
    
read_argv0szCommand);
    
    if( 
equalszCommandszJoinCommand )
    && 
CS_TEAM_T <= cs_get_user_teamclient ) <= CS_TEAM_CT )
    {
        
console_printclient"You cannot use this command.!" );
        return 
PLUGIN_HANDLED;
    }
    
    return 
PLUGIN_CONTINUE;



YamiKaitou 05-10-2013 00:09

Re: [HELP] block commands console
 
You cannot block client cvars and not every client command can be blocked. Provide a complete list of the commands or try them yourself.

joyceteamo 05-10-2013 10:39

Re: [HELP] block commands console
 
Quote:

Originally Posted by YamiKaitou (Post 1949142)
You cannot block client cvars and not every client command can be blocked. Provide a complete list of the commands or try them yourself.


I would like to specifically block in the console commands fps_max and fps_override

YamiKaitou 05-10-2013 14:07

Re: [HELP] block commands console
 
They are cvars, not commands. It is not possible to prevent the client from modifying them

joyceteamo 05-10-2013 21:06

Re: [HELP] block commands console
 
Quote:

Originally Posted by YamiKaitou (Post 1949459)
They are cvars, not commands. It is not possible to prevent the client from modifying them

Ok thank you


All times are GMT -4. The time now is 10:57.

Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.