File tree Expand file tree Collapse file tree 2 files changed +12
-5
lines changed Expand file tree Collapse file tree 2 files changed +12
-5
lines changed Original file line number Diff line number Diff line change @@ -811,10 +811,20 @@ void CTFTeamMenu::OnTick()
811811
812812 int iCurrentTeam = pLocalPlayer->GetTeamNumber ();
813813
814+ int iTeamSize = kMVM_DefendersTeamSize ;
815+
816+ #ifndef VALVE_PURE
817+ ConVarRef tf_sv_mvm_forced_players (" tf_sv_mvm_forced_players" );
818+ if (tf_sv_mvm_forced_players.GetInt () > iTeamSize)
819+ {
820+ iTeamSize = tf_sv_mvm_forced_players.GetInt ();
821+ }
822+ #endif
823+
814824 if ( ( bUnbalanced && iHeavyTeam == TF_TEAM_RED ) ||
815825 ( pRules->WouldChangeUnbalanceTeams ( TF_TEAM_RED, iCurrentTeam ) ) ||
816826 ( bHighlander && GetGlobalTeam ( TF_TEAM_RED )->GetNumPlayers () >= TF_LAST_NORMAL_CLASS - 1 ) ||
817- ( pRules->IsMannVsMachineMode () && ( GetGlobalTeam ( TF_TEAM_RED )->GetNumPlayers () >= kMVM_DefendersTeamSize ) ) )
827+ ( pRules->IsMannVsMachineMode () && ( GetGlobalTeam ( TF_TEAM_RED )->GetNumPlayers () >= iTeamSize ) ) )
818828 {
819829 m_bRedDisabled = true ;
820830 }
Original file line number Diff line number Diff line change @@ -1593,10 +1593,6 @@ void CTFGCServerSystem::ClientDisconnected( CSteamID steamIDClient )
15931593 }
15941594}
15951595
1596- #ifndef VALVE_PURE
1597- extern ConVar tf_sv_mvm_forced_players;
1598- #endif
1599-
16001596// -----------------------------------------------------------------------------
16011597void CTFGCServerSystem::PreClientUpdate ( )
16021598{
@@ -1703,6 +1699,7 @@ void CTFGCServerSystem::PreClientUpdate( )
17031699
17041700 int playerCount = kMVM_DefendersTeamSize + spectatorCount;
17051701#ifndef VALVE_PURE
1702+ ConVarRef tf_sv_mvm_forced_players (" tf_sv_mvm_forced_players" );
17061703 if ( tf_sv_mvm_forced_players.GetInt () > playerCount )
17071704 {
17081705 playerCount = tf_sv_mvm_forced_players.GetInt ();
You can’t perform that action at this time.
0 commit comments