From ec3adca9e3fae1ca003273bb5bd5326756499147 Mon Sep 17 00:00:00 2001 From: kingofings <47538464+kingofings@users.noreply.github.com> Date: Sat, 5 Jul 2025 14:23:21 +0200 Subject: [PATCH] include in previous if --- src/game/shared/tf/tf_weaponbase.cpp | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/src/game/shared/tf/tf_weaponbase.cpp b/src/game/shared/tf/tf_weaponbase.cpp index 6266516c8..5df220b3c 100644 --- a/src/game/shared/tf/tf_weaponbase.cpp +++ b/src/game/shared/tf/tf_weaponbase.cpp @@ -2088,13 +2088,10 @@ void CTFWeaponBase::IncrementAmmo( void ) } else if ( !CheckReloadMisfire() ) { - if ( pPlayer && pPlayer->GetAmmoCount( m_iPrimaryAmmoType ) > 0 ) + if ( pPlayer && pPlayer->GetAmmoCount( m_iPrimaryAmmoType ) > 0 && m_iClip1 < GetMaxClip1() ) { - if ( m_iClip1 < GetMaxClip1() ) - { - m_iClip1++; - pPlayer->RemoveAmmo( 1, m_iPrimaryAmmoType ); - } + m_iClip1++; + pPlayer->RemoveAmmo( 1, m_iPrimaryAmmoType ); } } }