local status = game:GetService("ReplicatedStorage").status local gameInProgress = 30 local gameOver = 1 while true do for timer = 45,1-1 do status.Value = "Intermission: "..timer wait(1) end local mapsFolder = game.ServerStorage.Maps:GetChildren() local randomMap = mapsFolder[math.random(1, #mapsFolder)] randomMap.Parent = workspace.CurrentMap local spawns = randomMap.Spawns:GetChildren() local teleport = spawns[math.random(1, #spawns)] for z = 15,1 ,-1 do status.Value = "Teleporting players to map in: "..z.." seconds" wait(1) end for i,plr in pairs(game.Players:GetPlayers()) do plr.Character:MoveTo(teleport.Position) end for b = gameInProgress,0,-1 do status.Value = "Game in progress: "..b.." seconds remaining" wait(1) end for c = gameOver,0,-1 do status.Value = "Round has ended!" wait(1) end
So I recently decided to script a game round script, but an issue has occurred. After 3 or 4 rounds the UI textlabel doesn't change to the desired teleportation text, instead it stays at "Round Over". If someone could help me identify the issue to this so I can resolve it that'd me great.
randomMap:Destroy() wait(1) end