final Player tmp = getClient().getPlayer();
final Party party = tmp.getParty();
if (tmp != null && party != null && party.equals(_player.getParty()) && !party.isLeader(_player))
writeC(0x01); // team circle around feet 1= Blue, 2 = red
else if (tmp != null && party != null && party.equals(_player.getParty()) && party.isLeader(_player))
writeC(0x02); // team circle around feet 1= Blue, 2 = red
else
writeC(_player.getTeam().getId());
this is for red and blue. Also broadcastCharInfo in Party/Disband, Leave and you are good. for different colors im not sure if its possible.