mirror of
https://github.com/shawns-valve/halflife.git
synced 2024-11-21 20:11:14 +00:00
Merge pull request #1580 from DanielOaks/zombie-pitch
Make zombie pitches more uniform, fix unused variable
This commit is contained in:
commit
5d761709a3
1 changed files with 5 additions and 3 deletions
|
@ -169,16 +169,18 @@ void CZombie :: AlertSound( void )
|
|||
|
||||
void CZombie :: IdleSound( void )
|
||||
{
|
||||
int pitch = 95 + RANDOM_LONG(0,9);
|
||||
int pitch = 100 + RANDOM_LONG(-5,5);
|
||||
|
||||
// Play a random idle sound
|
||||
EMIT_SOUND_DYN ( ENT(pev), CHAN_VOICE, pIdleSounds[ RANDOM_LONG(0,ARRAYSIZE(pIdleSounds)-1) ], 1.0, ATTN_NORM, 0, 100 + RANDOM_LONG(-5,5) );
|
||||
EMIT_SOUND_DYN ( ENT(pev), CHAN_VOICE, pIdleSounds[ RANDOM_LONG(0,ARRAYSIZE(pIdleSounds)-1) ], 1.0, ATTN_NORM, 0, pitch );
|
||||
}
|
||||
|
||||
void CZombie :: AttackSound( void )
|
||||
{
|
||||
int pitch = 100 + RANDOM_LONG(-5,5);
|
||||
|
||||
// Play a random attack sound
|
||||
EMIT_SOUND_DYN ( ENT(pev), CHAN_VOICE, pAttackSounds[ RANDOM_LONG(0,ARRAYSIZE(pAttackSounds)-1) ], 1.0, ATTN_NORM, 0, 100 + RANDOM_LONG(-5,5) );
|
||||
EMIT_SOUND_DYN ( ENT(pev), CHAN_VOICE, pAttackSounds[ RANDOM_LONG(0,ARRAYSIZE(pAttackSounds)-1) ], 1.0, ATTN_NORM, 0, pitch );
|
||||
}
|
||||
|
||||
|
||||
|
|
Loading…
Reference in a new issue