From 34ca142d110195e191bbcdd4ccec986d66414f66 Mon Sep 17 00:00:00 2001 From: terencehill Date: Thu, 16 Aug 2018 13:44:10 +0200 Subject: [PATCH] Keepaway: don't allow players to get the ball if game hasn't started yet --- qcsrc/common/gamemodes/gamemode/keepaway/keepaway.qc | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/qcsrc/common/gamemodes/gamemode/keepaway/keepaway.qc b/qcsrc/common/gamemodes/gamemode/keepaway/keepaway.qc index c8bfbf25a..48ab656c0 100644 --- a/qcsrc/common/gamemodes/gamemode/keepaway/keepaway.qc +++ b/qcsrc/common/gamemodes/gamemode/keepaway/keepaway.qc @@ -89,8 +89,9 @@ void ka_TimeScoring(entity this) void ka_TouchEvent(entity this, entity toucher) // runs any time that the ball comes in contact with something { - if(game_stopped) return; - if(!this) return; + if (!this || game_stopped || time < game_starttime) + return; + if(trace_dphitq3surfaceflags & Q3SURFACEFLAG_NOIMPACT) { // The ball fell off the map, respawn it since players can't get to it ka_RespawnBall(this); -- 2.39.2