Eh, dunno.

This commit is contained in:
zaCade 2017-10-12 21:52:59 +02:00
parent f67b801d61
commit 5c8a765776

View File

@ -78,12 +78,11 @@ public Action OnUse(int entity, int client)
{ {
if(!bGaveAmmo) if(!bGaveAmmo)
{ {
int iWeapon = GetPlayerWeaponSlot(client, CS_SLOT_PRIMARY); int iWeapon = INVALID_ENT_REFERENCE;
if(iWeapon != -1) if((iWeapon = GetPlayerWeaponSlot(client, CS_SLOT_PRIMARY)) != INVALID_ENT_REFERENCE)
StockPlayerAmmo(client, iWeapon); StockPlayerAmmo(client, iWeapon);
iWeapon = GetPlayerWeaponSlot(client, CS_SLOT_SECONDARY); if((iWeapon = GetPlayerWeaponSlot(client, CS_SLOT_SECONDARY)) != INVALID_ENT_REFERENCE)
if(iWeapon != -1)
StockPlayerAmmo(client, iWeapon); StockPlayerAmmo(client, iWeapon);
bGaveAmmo = true; bGaveAmmo = true;