SampSharp: BasePlayer.GetAll method does not return the expected value
The problem is simple, for example, if there are 4 players on the server and then one disconnects, BasePlayer.GetAll
returns all 4 instances, instead of 3. That is, it is taking the instance of the player that disconnected.
This generated an exception (NullPointerException
) in a system that I was doing.
What should I do about it?
About this issue
- Original URL
- State: closed
- Created 4 years ago
- Comments: 21 (21 by maintainers)
I think better use BasePlayer.All instead as is the collection as array, though GetAll guess is a issue