From 54e706e1fbfb0fe8d811f6a79557a9a1ac839b8b Mon Sep 17 00:00:00 2001 From: Martin Taibr Date: Sun, 22 Mar 2020 12:01:11 +0100 Subject: [PATCH] remove unused global: game_completion_ratio --- qcsrc/server/defs.qh | 1 - qcsrc/server/g_world.qc | 8 -------- 2 files changed, 9 deletions(-) diff --git a/qcsrc/server/defs.qh b/qcsrc/server/defs.qh index 29621f61d..910ea215f 100644 --- a/qcsrc/server/defs.qh +++ b/qcsrc/server/defs.qh @@ -140,7 +140,6 @@ float blockSpectators; //if set, new or existing spectators or observers will be .float spectatortime; //point in time since the client is spectating or observing void checkSpectatorBlock(entity this); -float game_completion_ratio; // 0 at start, 1 near end .float winning; .float jointime; // time of connecting .float startplaytime; // time of switching from spectator to player diff --git a/qcsrc/server/g_world.qc b/qcsrc/server/g_world.qc index aa4c5f505..8ec26efd6 100644 --- a/qcsrc/server/g_world.qc +++ b/qcsrc/server/g_world.qc @@ -1800,9 +1800,6 @@ float WinningCondition_Scores(float limit, float leadlimit) limitreached = (limitreached || leadlimitreached); } - if(limit) - game_completion_ratio = max(game_completion_ratio, bound(0, WinningConditionHelper_topscore / limit, 1)); - return GetWinningCode( WinningConditionHelper_topscore && limitreached, WinningConditionHelper_equality @@ -1940,11 +1937,6 @@ void CheckRules_World() float wantovertime; wantovertime = 0; - if(timelimit > game_starttime) - game_completion_ratio = (time - game_starttime) / (timelimit - game_starttime); - else - game_completion_ratio = 0; - if(checkrules_suddendeathend) { if(!checkrules_suddendeathwarning) -- 2.39.2