Basically, I need to script to be a timer script that's the same for everyone, not local. I'm currently experiencing problems that whenever I reset/die, the time resets back to its full time. How would I make it so the time is the same for all the players, I tried creating an IntValue, but it's not working. Script below...
t=game.Workspace:FindFirstChild("Timer").Value
while true do
wait()
t=t+30
for i=1, 30 do
t=t-1
wait(1)
for i, player in pairs(game.Players:GetPlayers()) do
player.PlayerGui.TimerSet.Frame.Time.Text=tostring(t)
end
end
t=t+45
for i=1, 45 do
t=t-1
wait(1)
for i, player in pairs(game.Players:GetPlayers()) do
player.PlayerGui.TimerSet.Frame.Time.Text=tostring(t)
end
end
for i, player in pairs(game.Players:GetPlayers()) do
player.Character.Humanoid.Health = 0
player.Character.Humanoid.MaxHealth = 0
end
end
Thanks!

2 comments
Is this in a localscript?
No, It's not.