Please help me I cant figure it out.
local roundLength = 120 local intermissionLength = 15 local Status = game.ReplicatedStorage.Status local inRound = game.ReplicatedStorage.InRound local Lobby = game.Workspace.Lobby local Roundspawn = game.Workspace.Maps["Science Lab"].ScienceLabsSpawns.ScienceLabSpawn inRound.Changed:Connect(function() wait(1) if inRound.Value == true then for _, player in pairs(game.Players:GetChildren()) do local char = player.Character char.HumanoidRootPart.CFrame = Roundspawn.CFrame end else wait(1) for _, player in pairs(game.Players:GetChildren()) do local char = player.Character char.HumanoidRootPart.CFrame = Lobby.CFrame end end end) local function roundTimer() while wait() do for i = intermissionLength, 1, -1 do inRound.Value = false wait(1) Status.Value = "intermission: ".. i .." seconds left!" end for i = roundLength, 1, -1 do inRound.Value = true wait(1) Status.Value = "Game: ".. i .." seconds left" end end end spawn(roundTimer)
You see, the "inRound" value is never false, which is why it keeps on constantly teleporting you.
Fix it by adding
inRound.Value == false
under if inRound.Value == true then
then when your round ends, add
inRound.Value == true
to where the round ends to restart the loop