Basically, I want this script to constantly check the count of the blue team's players until it's 0and then I want to execute a script.
I don't know how to loop it..
1 | if #game.Teams.Runner:GetPlayers() = = 0 then |
2 | --do stuff |
3 | end |
In this case you would use a While
loop which is basically an if statement, but While something is equal to something or true, it will play the loop until it's not equal or false
in this case you can do
1 | while #game.Teams.Runner:GetPlayers() > 0 do |
2 | -- Whatever you want in here |
3 | end |
The wiki has some information on the types of loops and how they work here http://wiki.roblox.com/?title=Loops