summaryrefslogtreecommitdiff
path: root/src/game/g_mover.c
diff options
context:
space:
mode:
author/dev/humancontroller <devhc@example.com>2017-04-15 16:55:14 +0200
committer/dev/humancontroller <devhc@example.com>2017-04-15 16:55:14 +0200
commit7bfcf1fae886456c17e7e2fe9d47530ad1fd8162 (patch)
treef4aa7e2a417e90b10f741d0a11c6e3ce35480875 /src/game/g_mover.c
parentb0c9d60a370a1ae651e2850c3b07d6ffa1da69ce (diff)
do not treat a clipmask of 0 as MASK_DEADSOLID in some cases
remove the clipmask == 0 special cases from G_TestEntityPosition() and G_Physics(). when spawning corpses, set their clipmask to MASK_DEADSOLID instead of 0.
Diffstat (limited to 'src/game/g_mover.c')
-rw-r--r--src/game/g_mover.c10
1 files changed, 2 insertions, 8 deletions
diff --git a/src/game/g_mover.c b/src/game/g_mover.c
index 268a25d..74b6541 100644
--- a/src/game/g_mover.c
+++ b/src/game/g_mover.c
@@ -55,17 +55,11 @@ G_TestEntityPosition
gentity_t *G_TestEntityPosition( gentity_t *ent )
{
trace_t tr;
- int mask;
-
- if( ent->clipmask )
- mask = ent->clipmask;
- else
- mask = MASK_SOLID;
if( ent->client )
- trap_Trace( &tr, ent->client->ps.origin, ent->r.mins, ent->r.maxs, ent->client->ps.origin, ent->s.number, mask );
+ trap_Trace( &tr, ent->client->ps.origin, ent->r.mins, ent->r.maxs, ent->client->ps.origin, ent->s.number, ent->clipmask );
else
- trap_Trace( &tr, ent->s.pos.trBase, ent->r.mins, ent->r.maxs, ent->s.pos.trBase, ent->s.number, mask );
+ trap_Trace( &tr, ent->s.pos.trBase, ent->r.mins, ent->r.maxs, ent->s.pos.trBase, ent->s.number, ent->clipmask );
if( tr.startsolid )
return &g_entities[ tr.entityNum ];