mirror of
https://github.com/s1lentq/ReGameDLL_CS.git
synced 2024-12-27 07:05:38 +03:00
Revert mp_refill_bpammo_weapons 3
This commit is contained in:
parent
efb06a7a20
commit
b0d0ffedff
1
dist/game.cfg
vendored
1
dist/game.cfg
vendored
@ -93,6 +93,7 @@ mp_auto_reload_weapons 0
|
||||
// 0 - disabled (default behaviour)
|
||||
// 1 - refill backpack ammo on player spawn
|
||||
// 2 - refill backpack ammo on player spawn and on the purchase of the item
|
||||
// 3 - refill backpack ammo on each weapon reload (NOTE: Useful for mods like DeathMatch, GunGame, ZombieMod etc.)
|
||||
//
|
||||
// Default value: "0"
|
||||
mp_refill_bpammo_weapons 0
|
||||
|
@ -917,7 +917,15 @@ void CBasePlayerWeapon::ItemPostFrame()
|
||||
|
||||
// Add them to the clip
|
||||
m_iClip += j;
|
||||
|
||||
#ifdef REGAMEDLL_ADD
|
||||
// Do not remove bpammo of the player,
|
||||
// if cvar allows to refill bpammo on during reloading the weapons
|
||||
if (refill_bpammo_weapons.value < 3.0f)
|
||||
#endif
|
||||
{
|
||||
m_pPlayer->m_rgAmmo[m_iPrimaryAmmoType] -= j;
|
||||
}
|
||||
|
||||
m_pPlayer->TabulateAmmo();
|
||||
m_fInReload = FALSE;
|
||||
@ -1436,8 +1444,15 @@ bool EXT_FUNC CBasePlayerWeapon::__API_HOOK(DefaultShotgunReload)(int iAnim, int
|
||||
#endif
|
||||
{
|
||||
m_iClip++;
|
||||
|
||||
#ifdef REGAMEDLL_ADD
|
||||
if (refill_bpammo_weapons.value < 3.0f)
|
||||
#endif
|
||||
{
|
||||
m_pPlayer->m_rgAmmo[m_iPrimaryAmmoType]--;
|
||||
m_pPlayer->ammo_buckshot--;
|
||||
}
|
||||
|
||||
m_fInSpecialReload = 1;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user