From 9c52ce8f1056c57b9d0a3722a096d1697b6d1a09 Mon Sep 17 00:00:00 2001 From: Bryce Hutchings Date: Fri, 19 Jul 2002 04:29:02 +0000 Subject: [PATCH] can return case with any weapon in hand --- reaction/game/g_team.c | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/reaction/game/g_team.c b/reaction/game/g_team.c index 986856c4..a271a123 100644 --- a/reaction/game/g_team.c +++ b/reaction/game/g_team.c @@ -5,6 +5,9 @@ //----------------------------------------------------------------------------- // // $Log$ +// Revision 1.12 2002/07/19 04:29:02 niceass +// can return case with any weapon in hand +// // Revision 1.11 2002/06/29 04:15:15 jbravo // CTF is now CTB. no weapons while the case is in hand other than pistol or knife // @@ -804,10 +807,6 @@ int Pickup_Team(gentity_t * ent, gentity_t * other) int team; gclient_t *cl = other->client; -// JBravo: no picking up case if you have a two handed weapon. - if (other->client->ps.weapon != WP_PISTOL && other->client->ps.weapon != WP_KNIFE) { - return 0; - } // figure out what team this flag is if (strcmp(ent->classname, "team_CTF_redflag") == 0) { team = TEAM_RED; @@ -817,6 +816,12 @@ int Pickup_Team(gentity_t * ent, gentity_t * other) PrintMsg(other, "Don't know what team the flag is on.\n"); return 0; } + + // JBravo: no picking up [the enemy case-NiceAss] case if you have a two handed weapon. + if (other->client->ps.weapon != WP_PISTOL && other->client->ps.weapon != WP_KNIFE && + team != cl->sess.sessionTeam) { + return 0; + } // GT_CTF if (team == cl->sess.sessionTeam) { return Team_TouchOurFlag(ent, other, team);