14.06.2011, 04:12
Take a look :
pawn Код:
enum E_TEAMS ( <<= 1 )
{
TEAM_VAGOS,
TEAM_GROVE
}
new E_TEAMS: gTeam[ MAX_PLAYERS ] = { TEAM_VAGOS, ... };
public OnPlayerRequestClass( playerid, classid )
{
switch ( classid )
{
case 0: gTeam[ playerid ] = TEAM_VAGOS;
}
return 1;
}
public OnPlayerDeath( playerid, killerid, reason )
{
if ( gTeam[ killerid ] == gTeam[ playerid ] )
{
GameTextForPlayer( killerid, "~w~BANNED FOR TEAMKILLING", 1000, 3 );
Ban( killerid );
}
return 1;
}