mirror of
https://github.com/ddnet/ddnet.git
synced 2024-11-10 10:08:18 +00:00
Don't clamp team quietly, but crash on invalid team
This commit is contained in:
parent
3078d9dcfc
commit
3aa29a9ea3
|
@ -20,7 +20,8 @@ int CTeamsCore::Team(int ClientID) const
|
|||
|
||||
void CTeamsCore::Team(int ClientID, int Team)
|
||||
{
|
||||
m_Team[ClientID] = clamp(Team, (int)TEAM_FLOCK, (int)TEAM_SUPER);
|
||||
dbg_assert(Team >= TEAM_FLOCK && Team <= TEAM_SUPER, "invalid team");
|
||||
m_Team[ClientID] = Team;
|
||||
}
|
||||
|
||||
bool CTeamsCore::CanKeepHook(int ClientID1, int ClientID2) const
|
||||
|
|
Loading…
Reference in a new issue