(#5016) - Calls to trap_CM_PointContents don't update their origins based on moving entities (water). Patch by Ensiform
This commit is contained in:
parent
960dca2cd4
commit
eec06674fa
5 changed files with 12 additions and 11 deletions
|
@ -2027,8 +2027,8 @@ static void CG_ShotgunPellet( vec3_t start, vec3_t end, int skipNum ) {
|
|||
|
||||
CG_Trace( &tr, start, NULL, NULL, end, skipNum, MASK_SHOT );
|
||||
|
||||
sourceContentType = trap_CM_PointContents( start, 0 );
|
||||
destContentType = trap_CM_PointContents( tr.endpos, 0 );
|
||||
sourceContentType = CG_PointContents( start, 0 );
|
||||
destContentType = CG_PointContents( tr.endpos, 0 );
|
||||
|
||||
// FIXME: should probably move this cruft into CG_BubbleTrail
|
||||
if ( sourceContentType == destContentType ) {
|
||||
|
@ -2115,7 +2115,7 @@ void CG_ShotgunFire( entityState_t *es ) {
|
|||
// ragepro can't alpha fade, so don't even bother with smoke
|
||||
vec3_t up;
|
||||
|
||||
contents = trap_CM_PointContents( es->pos.trBase, 0 );
|
||||
contents = CG_PointContents( es->pos.trBase, 0 );
|
||||
if ( !( contents & CONTENTS_WATER ) ) {
|
||||
VectorSet( up, 0, 0, 8 );
|
||||
CG_SmokePuff( v, up, 32, 1, 1, 1, 0.33f, 900, cg.time, 0, LEF_PUFF_DONT_SCALE, cgs.media.shotgunSmokePuffShader );
|
||||
|
@ -2268,8 +2268,8 @@ void CG_Bullet( vec3_t end, int sourceEntityNum, vec3_t normal, qboolean flesh,
|
|||
// do trail effects
|
||||
if ( sourceEntityNum >= 0 && cg_tracerChance.value > 0 ) {
|
||||
if ( CG_CalcMuzzlePoint( sourceEntityNum, start ) ) {
|
||||
sourceContentType = trap_CM_PointContents( start, 0 );
|
||||
destContentType = trap_CM_PointContents( end, 0 );
|
||||
sourceContentType = CG_PointContents( start, 0 );
|
||||
destContentType = CG_PointContents( end, 0 );
|
||||
|
||||
// do a complete bubble trail if necessary
|
||||
if ( ( sourceContentType == destContentType ) && ( sourceContentType & CONTENTS_WATER ) ) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue