Is there a way for a script to check how many players are in a game?
In my game there's a glitch where if there's only 1 player in the game, they can get as many points as they want. I need some way for the game to check if they're at least 2 players. I'd use that to tell the script to only do its regular cycle if there is more than 1 player in the game. I tried using a way to detect the number of players on a team, but the way the script is structured, it always just ended up breaking the script.
Just wondering if there's a way and if you can link me to some resources so I can learn how.

4 comments
So on line 2 it would be something like if NumPlayer >= 2 then ??
Yeah, pretty much
It doesn't seem to be working. Even with 2 players it still thinks it's not enough players.
Well, not entirely. The reason it probably isn't working is because you're getting the amount of players when the server is created (assuming you're using a ServerScript). Before you start the game, check it.