PlayerCollection removes a Player when that Player is being looked for


I just ran into a bug where the PlayerLeft event would remove the player while an event that happened just before it needed to access that player.
I am implementing a fix where calls to RconClient.Players returns a copy of the PlayerCollection, and the PlayerLeft event will remove the player from the original PlayerCollection.
This will be marked as fixed but left open because that occurrence is too rare to be able to totally confirm it's fixed, but the fix should be sound.


Timiz0r wrote Oct 7, 2011 at 12:08 AM

I completely misread the situation. The onsquadchange event was happening after the player left, so of course there was no player. I'll now check to see that the player exists for the squad changed event.

While the issue originally stated could come up, it benefits performance to revert those changes.

wrote Nov 1, 2011 at 1:47 AM

Timiz0r wrote Nov 9, 2011 at 12:51 PM

The problem hasn't resurfaced.

** Closed by Timiz0r 10/31/2011 5:47 PM

Timiz0r wrote Nov 9, 2011 at 12:51 PM

Keeping bug reports open as fixed.

wrote Nov 9, 2011 at 12:52 PM

wrote Feb 13, 2013 at 6:23 PM

wrote May 15, 2013 at 5:09 AM

wrote May 15, 2013 at 5:09 AM

wrote Jun 12, 2013 at 2:02 AM