From 08557f576942fd17dfe6d51b514a317cdd703c0b Mon Sep 17 00:00:00 2001 From: Night Owl Date: Mon, 25 Jun 2018 22:18:21 +0500 Subject: [PATCH] Fix crash. --- dlls/hunger/hand.cpp | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/dlls/hunger/hand.cpp b/dlls/hunger/hand.cpp index 2bc841a8..6488f7a0 100644 --- a/dlls/hunger/hand.cpp +++ b/dlls/hunger/hand.cpp @@ -134,9 +134,7 @@ void CEinarHand::SetYawSpeed() //========================================================= void CEinarHand::AttackSound() { - int iSound = RANDOM_LONG( 0, 2 ); - if( iSound != 0 ) - EMIT_SOUND_DYN( edict(), CHAN_VOICE, pAttackSounds[iSound], GetSoundVolue(), ATTN_IDLE, 0, GetVoicePitch() ); + EMIT_SOUND_DYN( edict(), CHAN_VOICE, RANDOM_SOUND_ARRAY( pAttackSounds ), GetSoundVolue(), ATTN_IDLE, 0, GetVoicePitch() ); } //=========================================================