From 45f299c1bf3912e791046e051b6d824f065eb299 Mon Sep 17 00:00:00 2001 From: Paweł Redman Date: Fri, 16 Nov 2018 19:09:46 +0100 Subject: Fix sign errors in bias calculations. --- src/game/g_main.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src') diff --git a/src/game/g_main.c b/src/game/g_main.c index 83ca299..2cb292d 100644 --- a/src/game/g_main.c +++ b/src/game/g_main.c @@ -2702,14 +2702,14 @@ static float AntistackTeamBias(int aliens, int humans) if (abs(aliens - humans) < g_antistackTeamBiasThreshold.integer) return 0.0f; - return (aliens - humans) * g_antistackTeamBiasFactor.value; + return (humans - aliens) * g_antistackTeamBiasFactor.value; } static float AntistackScoreBias(int alien_score, int human_score) { float bias; - bias = log((float)alien_score / human_score * g_antistackScoreBias.value); + bias = log((float)human_score / alien_score * g_antistackScoreBias.value); if (fabsf(bias) < g_antistackScoreBiasThreshold.value) return 0.0f; -- cgit