summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/game/g_active.c2
-rw-r--r--src/game/g_local.h2
-rw-r--r--src/game/g_weapon.c9
-rw-r--r--src/game/tremulous.h3
4 files changed, 9 insertions, 7 deletions
diff --git a/src/game/g_active.c b/src/game/g_active.c
index fbb746da..93ae76f0 100644
--- a/src/game/g_active.c
+++ b/src/game/g_active.c
@@ -995,7 +995,7 @@ void ClientThink_real( gentity_t *ent )
client->ps.pm_type = PM_NORMAL;
if( client->ps.stats[ STAT_STATE ] & SS_GRABBED &&
- client->lastGrabTime + LEVEL1_GRAB_TIME < level.time )
+ client->grabExpiryTime < level.time )
client->ps.stats[ STAT_STATE ] &= ~SS_GRABBED;
if( client->ps.stats[ STAT_STATE ] & SS_BLOBLOCKED &&
diff --git a/src/game/g_local.h b/src/game/g_local.h
index 80aa8375..30d0e42e 100644
--- a/src/game/g_local.h
+++ b/src/game/g_local.h
@@ -397,7 +397,7 @@ struct gclient_s
gentity_t *lastPoisonClient;
int lastPoisonCloudedTime;
gentity_t *lastPoisonCloudedClient;
- int lastGrabTime;
+ int grabExpiryTime;
int lastLockTime;
int lastSlowTime;
int lastBoostedTime;
diff --git a/src/game/g_weapon.c b/src/game/g_weapon.c
index 84773855..7094bcdb 100644
--- a/src/game/g_weapon.c
+++ b/src/game/g_weapon.c
@@ -813,10 +813,11 @@ void CheckGrabAttack( gentity_t *ent )
}
traceEnt->client->ps.stats[ STAT_STATE ] |= SS_GRABBED;
-
- //if getting damaged, don't reset the grab time
- if( ( ent->client->lastDamageTime + LEVEL1_GRAB_TIME ) < level.time )
- traceEnt->client->lastGrabTime = level.time;
+
+ if( ent->client->ps.weapon == WP_ALEVEL1 )
+ traceEnt->client->grabExpiryTime = level.time + LEVEL1_GRAB_TIME;
+ else if( ent->client->ps.weapon == WP_ALEVEL1_UPG )
+ traceEnt->client->grabExpiryTime = level.time + LEVEL1_GRAB_U_TIME;
}
else if( traceEnt->s.eType == ET_BUILDABLE &&
traceEnt->s.modelindex == BA_H_MGTURRET )
diff --git a/src/game/tremulous.h b/src/game/tremulous.h
index 4d74851d..ce0fbff4 100644
--- a/src/game/tremulous.h
+++ b/src/game/tremulous.h
@@ -49,7 +49,8 @@
#define LEVEL1_CLAW_REPEAT 600
#define LEVEL1_CLAW_U_REPEAT 500
#define LEVEL1_GRAB_RANGE 64.0f
-#define LEVEL1_GRAB_TIME 800
+#define LEVEL1_GRAB_TIME 300
+#define LEVEL1_GRAB_U_TIME 450
#define LEVEL1_PCLOUD_DMG ADM(4)
#define LEVEL1_PCLOUD_RANGE 200.0f
#define LEVEL1_PCLOUD_REPEAT 2000