Quote:
Originally Posted by OneMoreLevel
Is there a way that I can make it so that when you pick ct,t, or auto assign, it kicks you to ct, not t or auto assign.
I also need them still be able to go to spectator. Is this possible?
|
Not the best method but it works :-B
PHP Code:
#include <amxmodx>
#include <cstrike>
new g_iCurTeam[ 33 ] = { 'U' , ... };
public plugin_init()
{
register_plugin( "Change team example" , "1.0" , "bugsy" );
register_event( "TeamInfo" , "fw_EvTeamInfo" , "a" );
}
public fw_EvTeamInfo( )
{
static id; id = read_data( 1 );
static szTeam[ 2 ]; read_data( 2 , szTeam , 1 );
if ( g_iCurTeam[ id ] != szTeam[ 0 ] )
{
g_iCurTeam[ id ] = szTeam[ 0 ];
switch( szTeam[ 0 ] )
{
case 'T' , 'S':
{
cs_set_user_team( id , CS_TEAM_CT );
}
}
}
}
__________________