diff options
Diffstat (limited to 'src/cgame/cg_buildable.c')
-rw-r--r-- | src/cgame/cg_buildable.c | 15 |
1 files changed, 9 insertions, 6 deletions
diff --git a/src/cgame/cg_buildable.c b/src/cgame/cg_buildable.c index 03123e3c..9f91b56b 100644 --- a/src/cgame/cg_buildable.c +++ b/src/cgame/cg_buildable.c @@ -429,13 +429,16 @@ void CG_Buildable( centity_t *cent ) ent.axis[ 1 ][ 1 ] = -ent.axis[ 1 ][ 1 ]; ent.axis[ 1 ][ 2 ] = -ent.axis[ 1 ][ 2 ]; - VectorMA( ent.origin, -TRACE_DEPTH, surfNormal, end ); - VectorMA( ent.origin, 1.0f, surfNormal, start ); - CG_CapTrace( &tr, start, mins, maxs, end, es->number, MASK_PLAYERSOLID ); - VectorMA( ent.origin, tr.fraction * -TRACE_DEPTH, surfNormal, ent.origin ); - - VectorCopy( ent.origin, ent.lightingOrigin ); + if( es->pos.trType == TR_STATIONARY ) + { + VectorMA( ent.origin, -TRACE_DEPTH, surfNormal, end ); + VectorMA( ent.origin, 1.0f, surfNormal, start ); + CG_CapTrace( &tr, start, mins, maxs, end, es->number, MASK_PLAYERSOLID ); + VectorMA( ent.origin, tr.fraction * -TRACE_DEPTH, surfNormal, ent.origin ); + } + VectorCopy( ent.origin, ent.oldorigin ); // don't positionally lerp at all + VectorCopy( ent.origin, ent.lightingOrigin ); ent.hModel = cg_buildables[ es->modelindex ].models[ 0 ]; |