There are two terms in versus related to teams:
1) client team - which is changed once per each map for each player. Can be retrieved via GetClientTeam().
2) logical team - which is not changed during the whole campaign, unless you specially moved to another team.
To get the logical team from client index you can use the stock below:
PHP Code:
int GetLogicalTeam(int client)
{
return (GetClientTeam(client) ^ GameRules_GetProp("m_bAreTeamsFlipped", 1)) - 1;
}
__________________