garrynewman/garrysmod — pull request #716 by Mista-Tea (2014-05-31 01:04:54+00:00)
Title: Fix PLAYER:AddCount() causing PLAYER:GetCount() to report incorrect valu...

...es

About the issue:
http://facepunch.com/showthread.php?t=1348923&p=44954712&viewfull=1#post44954712
http://facepunch.com/showthread.php?t=1348923&p=44954892&viewfull=1#post44954892
http://facepunch.com/showthread.php?t=1348923&p=44955078&viewfull=1#post44955078

Somehow this only became an issue within the last 2 months even though this file hasn't been edited for a year.

Anyway, the whole 'minus' part about PLAYER:GetCount() and PLAYER:AddCount() is redundant because PLAYER:GetCount() already sanitizes the table of props and gets an accurate number. By subtracting 1 afterward, it is actually breaking it.