| 178 | } |
| 179 | |
| 180 | void newteam(char *name) |
| 181 | { |
| 182 | if(*name) |
| 183 | { |
| 184 | int nt = teamatoi(name); |
| 185 | if(nt == player1->team) return; // same team |
| 186 | if(!team_isvalid(nt)) { conoutf("\f3\"%s\" is not a valid team name or number", name); return; } |
| 187 | if(player1->state == CS_EDITING) conoutf("you can't change team while editing"); |
| 188 | else addmsg(SV_SWITCHTEAM, "ri", nt); |
| 189 | } |
| 190 | else conoutf("your team is: %s", team_string(player1->team)); |
| 191 | } |
| 192 | COMMANDN(team, newteam, "s"); |
| 193 | |
| 194 | void benchme() |
nothing calls this directly
no test coverage detected