My game needs at least two players to begin. My script won't continue even if I have two players in my test server.
while true do
print("this works") -- this prints over and over again even though I am using the Test feature with two players
wait(1)
contestants = {}
for _, player in pairs(game.Players:GetPlayers()) do
local humanoid = player.Character:WaitForChild("Humanoid")
if humanoid and humanoid.Health > 0 then
table.insert(contestants, player)
end
end
end
if #contestants >= 2 then
print("we have enough") -- this does not print
break
end
Thanks in advance :)

1 comment
To add on to the question and this, use >= rather than > as you are saying at least