generic image
Processing...
  • Games
  • Catalog
  • Develop
  • Robux
  • Search in Players
  • Search in Games
  • Search in Catalog
  • Search in Groups
  • Search in Library
  • Log In
  • Sign Up
  • Games
  • Catalog
  • Develop
  • Robux
   
ROBLOX Forum » Game Creation and Development » Scripters
Home Search
 

Game Round Script adding up and overlapping..

Previous Thread :: Next Thread 
skilpus3000 is not online. skilpus3000
Joined: 20 Mar 2010
Total Posts: 846
26 Aug 2017 05:47 PM
I'm just about to finish a mini-game round script, it now it keeps bugging up.. There is a for-loop that starts running when there are 2 players online, and BREAKS when there's just 1 online. But every time 1 player leaves, and another joins, the for-loop is adding up once more, and starts doubling itself
Report Abuse
WrathVoid is not online. WrathVoid
Joined: 20 Apr 2011
Total Posts: 939
26 Aug 2017 05:47 PM
use game.Players.NumPlayers
Report Abuse
HeIIoISteaIUsernames is not online. HeIIoISteaIUsernames
Joined: 26 Oct 2012
Total Posts: 2906
26 Aug 2017 05:50 PM
NumPlayers is deprecated, just do #game.Players:GetPlayers() or :GetChildren()
Report Abuse
skilpus3000 is not online. skilpus3000
Joined: 20 Mar 2010
Total Posts: 846
26 Aug 2017 05:50 PM
There's nothing wrong with the amount of players, it is stored as an IntValue in ServerStorage, and is updated whenever a player joins/leaves :/
Report Abuse
TinyGravity is not online. TinyGravity
Joined: 30 Apr 2016
Total Posts: 262
26 Aug 2017 05:50 PM
@WrathVoid

That's deprecated
Use
game.Players:GetPlayers()
Report Abuse
skilpus3000 is not online. skilpus3000
Joined: 20 Mar 2010
Total Posts: 846
26 Aug 2017 06:00 PM
I don't get this.. why does it add up even when I break it??
Report Abuse
Previous Thread :: Next Thread 
Page 1 of 1
 
 
ROBLOX Forum » Game Creation and Development » Scripters
   
 
   
  • About Us
  • Jobs
  • Blog
  • Parents
  • Help
  • Terms
  • Privacy

©2017 Roblox Corporation. Roblox, the Roblox logo, Robux, Bloxy, and Powering Imagination are among our registered and unregistered trademarks in the U.S. and other countries.



Progress
Starting Roblox...
Connecting to Players...
R R

Roblox is now loading. Get ready to play!

R R

You're moments away from getting into the game!

Click here for help

Check Remember my choice and click Launch Application in the dialog box above to join games faster in the future!

Gameplay sponsored by:
Loading 0% - Starting game...
Get more with Builders Club! Join Builders Club
Choose Your Avatar
I have an account
generic image