From f5b2eb80cffd9ad90c22c6b9978263b1ae72bb6c Mon Sep 17 00:00:00 2001 From: div0 Date: Wed, 16 May 2007 21:00:34 +0000 Subject: [PATCH] fix unused stats feature git-svn-id: svn://svn.icculus.org/nexuiz/trunk@2572 f962a42d-fe04-0410-a3ab-8c8b0445ebaa --- data/qcsrc/server/g_world.qc | 24 +++++++++++++----------- 1 file changed, 13 insertions(+), 11 deletions(-) diff --git a/data/qcsrc/server/g_world.qc b/data/qcsrc/server/g_world.qc index e6b38d787..5a0769e71 100644 --- a/data/qcsrc/server/g_world.qc +++ b/data/qcsrc/server/g_world.qc @@ -945,8 +945,17 @@ void() NextLevel = GameLogClose(); - maxTotalFrags = 0; FOR_EACH_CLIENT(other) + { + FixIntermissionClient(other); + + if(other.winning) + bprint(other.netname, " ^7wins.\n"); + } + + minTotalFrags = 0; + maxTotalFrags = 0; + FOR_EACH_PLAYER(other) { if(maxTotalFrags < other.totalfrags) maxTotalFrags = other.totalfrags; @@ -954,18 +963,11 @@ void() NextLevel = minTotalFrags = other.totalfrags; } - FOR_EACH_CLIENT(other) + if(!currentbots) { - FixIntermissionClient(other); - - self = other; - - if(other.winning) - bprint(other.netname, " ^7wins.\n"); - - if(!currentbots) + FOR_EACH_PLAYER(other) { - score = (other.frags - minTotalFrags) / max(maxTotalFrags - minTotalFrags, 1); + score = (other.totalfrags - minTotalFrags) / max(maxTotalFrags - minTotalFrags, 1); f = bound(0, other.play_time / max(time, 1), 1); // store some statistics? } -- 2.39.2