I get no errors or anything. Please help.
It's funny, when I take out the Changed event and just test it by disabling/enabling the script, everything works fine.
local h = Instance.new("Hint")
function countdown(cTime)
h.Parent = workspace
for i = 1,cTime do
h.Text = tonumber(cTime - i)
end
end
function votingVisible(bool)
for i,v in pairs(game.Players:GetPlayers()) do
v.PlayerGui.ScreenGui.Voting.Visible = bool
end
end
game.Players.Changed:connect(function()
if game.Players.NumPlayers == 1 then
h.Parent = workspace
h.Text = "Waiting for 2 players."
votingVisible(false)
elseif game.Players.NumPlayers == 2 then
votingVisible(true)
countdown(10)
votingVisible(false)
end
end)

2 comments
"Shouldn't you think after 2 players on the game" What do you mean by this?
I got it to work, no thanks to anyone on this website, but I appreciate you trying.