diff --git a/regamedll/dlls/player.cpp b/regamedll/dlls/player.cpp index 9a97f2c86..db77365a7 100644 --- a/regamedll/dlls/player.cpp +++ b/regamedll/dlls/player.cpp @@ -6667,7 +6667,7 @@ void CBasePlayer::HandleSignals() m_signals.Signal(SIGNAL_BOMB); } } -#endif +#endif if (!CSGameRules()->m_bMapHasBombZone) OLD_CheckBombTarget(this); @@ -8401,7 +8401,13 @@ void CStripWeapons::Use(CBaseEntity *pActivator, CBaseEntity *pCaller, USE_TYPE { if (m_iszSpecialItem) { - pPlayer->CSPlayer()->RemovePlayerItem(STRING(m_iszSpecialItem)); + const char *weaponName = STRING(m_iszSpecialItem); + WeaponSlotInfo *slotInfo = GetWeaponSlot(weaponName); + + if (slotInfo != nullptr && slotInfo->slot == GRENADE_SLOT) + pPlayer->CSPlayer()->RemovePlayerItemEx(weaponName, true); + else + pPlayer->CSPlayer()->RemovePlayerItem(weaponName); } for (int slot = PRIMARY_WEAPON_SLOT; slot <= ALL_OTHER_ITEMS; slot++) @@ -8422,7 +8428,11 @@ void CStripWeapons::Use(CBaseEntity *pActivator, CBaseEntity *pCaller, USE_TYPE { pPlayer->ForEachItem(slot, [pPlayer](CBasePlayerItem *pItem) { - pPlayer->CSPlayer()->RemovePlayerItem(STRING(pItem->pev->classname)); + if (pItem->iItemSlot() == GRENADE_SLOT) + pPlayer->CSPlayer()->RemovePlayerItemEx(STRING(pItem->pev->classname), true); + else + pPlayer->CSPlayer()->RemovePlayerItem(STRING(pItem->pev->classname)); + return false; }); }