From 925987dfbef8006ae487e3e5219cf318b0ce1fd6 Mon Sep 17 00:00:00 2001 From: Molgrum Date: Fri, 23 Nov 2007 18:27:30 +0000 Subject: [PATCH] Security measures to prevent cheating with instant-join. git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@2795 fc73d0e0-1445-4013-8a0c-d673dee63da5 --- engine/client/cl_parse.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/engine/client/cl_parse.c b/engine/client/cl_parse.c index e3f766fdd..9085e0eb1 100644 --- a/engine/client/cl_parse.c +++ b/engine/client/cl_parse.c @@ -3006,9 +3006,15 @@ void CL_ProcessUserInfo (int slot, player_info_t *player) else player->spectator = false; + // If it's us if (slot == cl.playernum[0] && player->name[0]) + { cl.spectator = player->spectator; + // Update the rules since spectators can bypass everything but players can't + CL_CheckServerInfo(); + } + player->model = NULL; if (cls.state == ca_active)