summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/cgame/cg_weapons.c20
-rw-r--r--src/game/g_weapon.c2
2 files changed, 20 insertions, 2 deletions
diff --git a/src/cgame/cg_weapons.c b/src/cgame/cg_weapons.c
index ac0f6a14..b020c8bb 100644
--- a/src/cgame/cg_weapons.c
+++ b/src/cgame/cg_weapons.c
@@ -1816,7 +1816,25 @@ void CG_MissileHitEntity( weapon_t weaponNum, weaponMode_t weaponMode,
weaponMode = WPM_PRIMARY;
if( weapon->wim[ weaponMode ].alwaysImpact )
- CG_MissileHitWall( weaponNum, weaponMode, 0, origin, dir, IMPACTSOUND_FLESH, charge );
+ {
+ int sound;
+
+ if( cg_entities[ entityNum ].currentState.eType == ET_PLAYER )
+ {
+ // Players
+ sound = IMPACTSOUND_FLESH;
+ }
+ else if( cg_entities[ entityNum ].currentState.eType == ET_BUILDABLE &&
+ BG_Buildable( cg_entities[ entityNum ].currentState.modelindex )->team == TEAM_ALIENS )
+ {
+ // Alien buildables
+ sound = IMPACTSOUND_FLESH;
+ }
+ else
+ sound = IMPACTSOUND_DEFAULT;
+
+ CG_MissileHitWall( weaponNum, weaponMode, 0, origin, dir, sound, charge );
+ }
}
diff --git a/src/game/g_weapon.c b/src/game/g_weapon.c
index d5eda5ab..beb91429 100644
--- a/src/game/g_weapon.c
+++ b/src/game/g_weapon.c
@@ -252,7 +252,7 @@ static void BloodSpurt( gentity_t *attacker, gentity_t *victim, trace_t *tr )
tent->s.eventParm = DirToByte( tr->plane.normal );
tent->s.weapon = attacker->s.weapon;
tent->s.generic1 = attacker->s.generic1; // weaponMode
- }
+}
/*
===============