Skip to content

Commit

Permalink
Fix dropped weapons + ammo counting towards logic_pickups.
Browse files Browse the repository at this point in the history
  • Loading branch information
JetBoom committed Nov 26, 2014
1 parent 64bd994 commit e9cf988
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,9 @@ function ENT:Use(activator, caller)

activator:GiveAmmo(self:GetAmmo(), self:GetAmmoType())

activator.AmmoPickups = (activator.AmmoPickups or 0) + 1
if self.PlacedInMap then
activator.AmmoPickups = (activator.AmmoPickups or 0) + 1
end

self:RemoveNextFrame(0)
else
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,9 @@ function ENT:Use(activator, caller)
wep:SetClip2(self:GetClip2())
end

activator.WeaponPickups = (activator.WeaponPickups or 0) + 1
if self.PlacedInMap then
activator.WeaponPickups = (activator.WeaponPickups or 0) + 1
end

self:RemoveNextFrame()
end
Expand Down

0 comments on commit e9cf988

Please sign in to comment.