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
 

Re: so GetChildren is a boolean now

Previous Thread :: Next Thread 
Intern33t is not online. Intern33t
Joined: 19 Nov 2010
Total Posts: 1530
10 May 2015 12:15 PM
local play = {}
for a, v in pairs(game.Players:GetChildren()) do
if v:IsA("Player") then
play[a] = v
end
end

if not #play > 1 then --error fires here
repeat wait()
change("Need 2 Players to start...")
for a, v in pairs(game.Players:GetChildren()) do
if v:IsA("Player") then
play[a] = v
end
end
until #play > 1
end

or i tried

if not #game.Players:GetChildren() > 1 ...


both say the error:
attempt to compare number with boolean
Report Abuse
epicbreaker is not online. epicbreaker
Joined: 23 Apr 2011
Total Posts: 2791
10 May 2015 12:16 PM
if game.Players.NumPlayers <= 1 then
Report Abuse
Intern33t is not online. Intern33t
Joined: 19 Nov 2010
Total Posts: 1530
10 May 2015 12:19 PM
didnt knwo that existed

gg anyways while i typed it studio crashed.. :'(
Report Abuse
warspyking is not online. warspyking
Joined: 15 Nov 2011
Total Posts: 13947
10 May 2015 12:20 PM
if #game.Players:GetPlayers() <= 2 then
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