Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
1

My function is not firing properly?

Asked by 4 years ago

I have a script that is supposed to repeatedly fire two functions. The top one fires once and then doesnt fire the second one. Any help?

repeat
StartRound()
TimerScript()
until (#game.Teams.Spectating:GetPlayers() <= 1)

its supposed to only fire when theres 2 or more players on the "Spectating" team

1 answer

Log in to vote
0
Answered by 4 years ago
Edited 4 years ago

Hello, I am not sure if you meant this, but this might be the fix:


repeat StartRound() TimerScript() until (#game.Teams.Spectating:GetChildren() >=2)

OR


repeat StartRound() TimerScript() until (#game.Teams.Spectating:GetPlayers() >= 2)

Hope this helps!

Ad

Answer this question