Updated some other silly thing I should have noticed.
This commit is contained in:
parent
1530866829
commit
d63b9341c9
3 changed files with 4 additions and 3 deletions
|
@ -75,7 +75,7 @@ void TraceAttack_FireBullets( int iShots, vector vPos ) {
|
||||||
vector vDir;
|
vector vDir;
|
||||||
makevectors(self.v_angle);
|
makevectors(self.v_angle);
|
||||||
|
|
||||||
while ( iShots > 0) {
|
while ( iShots > 0 ) {
|
||||||
iTotalPenetrations = 0;
|
iTotalPenetrations = 0;
|
||||||
vDir = aim( self, 100000 ) + Math_CRandom()*self.fAccuracy*v_right + Math_CRandom()*self.fAccuracy*v_up;
|
vDir = aim( self, 100000 ) + Math_CRandom()*self.fAccuracy*v_right + Math_CRandom()*self.fAccuracy*v_up;
|
||||||
TraceAttack_FireSingle( vPos, vDir );
|
TraceAttack_FireSingle( vPos, vDir );
|
||||||
|
|
|
@ -34,14 +34,16 @@ int BaseMelee_Attack( void ) {
|
||||||
vSource = ( self.origin + self.view_ofs );
|
vSource = ( self.origin + self.view_ofs );
|
||||||
traceline( vSource, vSource + ( v_forward * 64 ), MOVE_HITMODEL, self );
|
traceline( vSource, vSource + ( v_forward * 64 ), MOVE_HITMODEL, self );
|
||||||
|
|
||||||
if ( trace_fraction == 1.0 )
|
if ( trace_fraction == 1.0 ) {
|
||||||
return FALSE;
|
return FALSE;
|
||||||
|
}
|
||||||
|
|
||||||
vOrigin = trace_endpos - v_forward * 2;
|
vOrigin = trace_endpos - v_forward * 2;
|
||||||
|
|
||||||
if ( trace_ent.takedamage ) {
|
if ( trace_ent.takedamage ) {
|
||||||
if ( trace_ent.iBleeds == TRUE ) {
|
if ( trace_ent.iBleeds == TRUE ) {
|
||||||
Effect_Impact( IMPACT_FLESH, trace_endpos, trace_plane_normal );
|
Effect_Impact( IMPACT_FLESH, trace_endpos, trace_plane_normal );
|
||||||
|
sound( self, CHAN_WEAPON, sprintf( "weapons/knife_hit%d.wav", floor( ( random() * 4 ) + 1 ) ), 1, ATTN_NORM );
|
||||||
}
|
}
|
||||||
Damage_Apply( trace_ent, self, wptTable[ self.weapon ].iDamage, trace_endpos );
|
Damage_Apply( trace_ent, self, wptTable[ self.weapon ].iDamage, trace_endpos );
|
||||||
} else {
|
} else {
|
||||||
|
|
|
@ -95,7 +95,6 @@ void Effect_Impact( int iType, vector vPos, vector vNormal ) {
|
||||||
pointsound( vPos, sprintf( "weapons/ric_metal-%d.wav", floor( ( random() * 2 ) + 1 ) ), 1, ATTN_STATIC );
|
pointsound( vPos, sprintf( "weapons/ric_metal-%d.wav", floor( ( random() * 2 ) + 1 ) ), 1, ATTN_STATIC );
|
||||||
break;
|
break;
|
||||||
case IMPACT_FLESH:
|
case IMPACT_FLESH:
|
||||||
pointsound( vPos, sprintf( "weapons/knife_hit%d.wav", floor( ( random() * 4 ) + 1 ) ), 1, ATTN_STATIC );
|
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
pointsound( vPos, sprintf( "weapons/ric%d.wav", floor( ( random() * 5 ) + 1 ) ), 1, ATTN_STATIC );
|
pointsound( vPos, sprintf( "weapons/ric%d.wav", floor( ( random() * 5 ) + 1 ) ), 1, ATTN_STATIC );
|
||||||
|
|
Loading…
Reference in a new issue