From 80b7d52eebc988058c9787237fd39bea1f81ce26 Mon Sep 17 00:00:00 2001 From: erorcun Date: Fri, 20 Aug 2021 21:59:50 +0300 Subject: Auto switch to remote grenade after detonator --- src/peds/PlayerPed.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'src/peds') diff --git a/src/peds/PlayerPed.cpp b/src/peds/PlayerPed.cpp index e486d4ce..2c6330aa 100644 --- a/src/peds/PlayerPed.cpp +++ b/src/peds/PlayerPed.cpp @@ -777,7 +777,8 @@ spentAmmoCheck: // BUG: m_nSelectedWepSlot and GetWeapon(..) takes slot in VC but they compared them against weapon types in whole condition! jeez #ifdef FIX_BUGS - if (m_nSelectedWepSlot == WEAPONSLOT_MELEE || GetWeapon(m_nSelectedWepSlot).m_nAmmoTotal > 0 && m_nSelectedWepSlot != WEAPONSLOT_PROJECTILE) { + if (m_nSelectedWepSlot == WEAPONSLOT_MELEE || + GetWeapon(m_nSelectedWepSlot).m_nAmmoTotal > 0 && (m_nSelectedWepSlot != WEAPONSLOT_PROJECTILE || GetWeapon(WEAPONSLOT_PROJECTILE).m_eWeaponType == WEAPONTYPE_DETONATOR_GRENADE)) { #else if (m_nSelectedWepSlot == WEAPONTYPE_BASEBALLBAT && GetWeapon(WEAPONTYPE_BASEBALLBAT).m_eWeaponType == WEAPONTYPE_BASEBALLBAT || GetWeapon(m_nSelectedWepSlot).m_nAmmoTotal > 0 -- cgit v1.2.3