From: Rudolf Polzer Date: Fri, 6 Jul 2012 10:50:36 +0000 (+0200) Subject: scorefactor 0.5 is too much; default to 0.25; also, never cause teams to become empty... X-Git-Tag: xonotic-v0.7.0~312^2~5 X-Git-Url: https://git.rm.cloudns.org/?a=commitdiff_plain;h=6a00227e026fb56b51431232107244ddb3ce2d55;p=xonotic%2Fxonotic-data.pk3dir.git scorefactor 0.5 is too much; default to 0.25; also, never cause teams to become empty by auto team switching --- diff --git a/defaultXonotic.cfg b/defaultXonotic.cfg index faa1aabd0..5e3924532 100644 --- a/defaultXonotic.cfg +++ b/defaultXonotic.cfg @@ -576,7 +576,7 @@ seta g_teamdamage_resetspeed 20 "for teamplay 4: how fast player's teamdamage co seta g_balance_teams 0 "automatically balance out players entering instead of asking them for their preferred team" seta g_balance_teams_prevent_imbalance 0 "prevent players from changing to larger teams" -set g_balance_teams_scorefactor 0.5 "at the end of the game, take score into account instead of team size by this amount" +set g_balance_teams_scorefactor 0.25 "at the end of the game, take score into account instead of team size by this amount (beware: values over 0.5 mean that a x:0 score imbalance will cause ALL new players to prefer the losing team at the end, despite numbers)" set g_tdm_teams 2 "how many teams are in team deathmatch (set by mapinfo)" seta g_tdm_teams_override 0 "how many teams are in team deathmatch" set g_tdm_team_spawns 0 "when 1, a map can define team spawnpoints for TDM" diff --git a/qcsrc/server/teamplay.qc b/qcsrc/server/teamplay.qc index ed9927dd7..f37167a49 100644 --- a/qcsrc/server/teamplay.qc +++ b/qcsrc/server/teamplay.qc @@ -664,6 +664,14 @@ float TeamSmallerEqThanTeam(float ta, float tb, entity e) } } + // keep teams alive (teams of size 0 always count as smaller, ignoring score) + if(ca < 1) + if(cb >= 1) + return TRUE; + if(ca >= 1) + if(cb < 1) + return FALSE; + // first, normalize f = max(ca, cb, 1); ca /= f;