Further fixes to antistick

This commit is contained in:
Richard Allen 2002-01-29 03:13:45 +00:00
parent 6067b5dead
commit 50eec79021
2 changed files with 23 additions and 1 deletions

View file

@ -5,6 +5,9 @@
//-----------------------------------------------------------------------------
//
// $Log$
// Revision 1.44 2002/01/29 03:13:45 jbravo
// Further fixes to antistick
//
// Revision 1.43 2002/01/27 13:33:28 jbravo
// Teamplay antistick system.
//
@ -1256,8 +1259,12 @@ void ClientThink_real( gentity_t *ent ) {
// JBravo: fixing telefragging and shit during spawnig. (Thanks NiceAss! :)
if (g_gametype.integer == GT_TEAMPLAY &&
((ent->client->ps.stats[STAT_RQ3] & RQ3_PLAYERSOLID) != RQ3_PLAYERSOLID)) {
((ent->client->ps.stats[STAT_RQ3] & RQ3_PLAYERSOLID) != RQ3_PLAYERSOLID) &&
!level.lights_camera_action) {
UnstickPlayer (ent);
}
if (g_gametype.integer == GT_TEAMPLAY &&
((ent->client->ps.stats[STAT_RQ3] & RQ3_PLAYERSOLID) != RQ3_PLAYERSOLID)) {
pm.tracemask = MASK_PLAYERSOLID & ~CONTENTS_BODY;
}

View file

@ -5,6 +5,9 @@
//-----------------------------------------------------------------------------
//
// $Log$
// Revision 1.7 2002/01/29 03:13:45 jbravo
// Further fixes to antistick
//
// Revision 1.6 2002/01/27 13:42:19 jbravo
// temp hack removed
//
@ -569,6 +572,18 @@ void UnstickPlayer( gentity_t *ent )
VectorAdd( ent->client->ps.origin, ent->r.mins, mins );
VectorAdd( ent->client->ps.origin, ent->r.maxs, maxs );
// JBravo: test
//#define PLAYERBOX 500
// mins[0] = -PLAYERBOX * 1.42;
// mins[1] = -PLAYERBOX * 1.42;
// mins[2] = -PLAYERBOX * 1.42;
// maxs[0] = PLAYERBOX * 1.42;
// maxs[1] = PLAYERBOX * 1.42;
// maxs[2] = PLAYERBOX * 1.42;
// VectorAdd( ent->client->ps.origin, mins, mins );
// VectorAdd( ent->client->ps.origin, maxs, maxs );
num = trap_EntitiesInBox( mins, maxs, touch, MAX_GENTITIES );
for (i=0 ; i<num ; i++) {