mirror of
https://github.com/ddnet/ddnet.git
synced 2024-11-19 22:48:18 +00:00
fixed a server problem on dbgstress
This commit is contained in:
parent
ff6fb5a71b
commit
ee253ddf57
|
@ -1126,17 +1126,16 @@ void IGameController::DoTeamChange(CPlayer *pPlayer, int Team, bool DoChatMsg)
|
||||||
|
|
||||||
int IGameController::GetStartTeam()
|
int IGameController::GetStartTeam()
|
||||||
{
|
{
|
||||||
// this will force the auto balancer to work overtime aswell
|
|
||||||
if(g_Config.m_DbgStress)
|
|
||||||
return TEAM_RED;
|
|
||||||
|
|
||||||
if(g_Config.m_SvTournamentMode)
|
if(g_Config.m_SvTournamentMode)
|
||||||
return TEAM_SPECTATORS;
|
return TEAM_SPECTATORS;
|
||||||
|
|
||||||
// determine new team
|
// determine new team
|
||||||
int Team = TEAM_RED;
|
int Team = TEAM_RED;
|
||||||
if(IsTeamplay())
|
if(IsTeamplay())
|
||||||
|
{
|
||||||
|
if(!g_Config.m_DbgStress) // this will force the auto balancer to work overtime aswell
|
||||||
Team = m_aTeamSize[TEAM_RED] > m_aTeamSize[TEAM_BLUE] ? TEAM_BLUE : TEAM_RED;
|
Team = m_aTeamSize[TEAM_RED] > m_aTeamSize[TEAM_BLUE] ? TEAM_BLUE : TEAM_RED;
|
||||||
|
}
|
||||||
|
|
||||||
// check if there're enough player slots left
|
// check if there're enough player slots left
|
||||||
if(m_aTeamSize[TEAM_RED]+m_aTeamSize[TEAM_BLUE] < Server()->MaxClients()-g_Config.m_SvSpectatorSlots)
|
if(m_aTeamSize[TEAM_RED]+m_aTeamSize[TEAM_BLUE] < Server()->MaxClients()-g_Config.m_SvSpectatorSlots)
|
||||||
|
|
Loading…
Reference in a new issue