From 41024d8d3711ec67df0fd8e64df20e43fec66622 Mon Sep 17 00:00:00 2001 From: Andrey Akhmichin Date: Mon, 25 Nov 2019 00:59:33 +0500 Subject: [PATCH] Fix toad viewmodel animation. --- dlls/squeakgrenade.cpp | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/dlls/squeakgrenade.cpp b/dlls/squeakgrenade.cpp index 7e8a9d92..67ab8351 100644 --- a/dlls/squeakgrenade.cpp +++ b/dlls/squeakgrenade.cpp @@ -35,6 +35,7 @@ enum w_squeak_e enum squeak_e { SQUEAK_IDLE1 = 0, + SQUEAK_IDLE2, SQUEAK_FIDGETFIT, SQUEAK_FIDGETNIP, SQUEAK_DOWN, @@ -565,11 +566,16 @@ void CSqueak::WeaponIdle( void ) int iAnim; float flRand = UTIL_SharedRandomFloat( m_pPlayer->random_seed, 0, 1 ); - if( flRand <= 0.75f ) + if( flRand <= 0.625f ) { iAnim = SQUEAK_IDLE1; m_flTimeWeaponIdle = UTIL_WeaponTimeBase() + 30.0f / 16.0f * 2.0f; } + else if( flRand <= 0.75f ) + { + iAnim = SQUEAK_IDLE2; + m_flTimeWeaponIdle = UTIL_WeaponTimeBase() + 30.0f / 16.0f * 2.0f; + } else if( flRand <= 0.875f ) { iAnim = SQUEAK_FIDGETFIT;