Here is the script
local maps = game:GetService("ServerStorage").Maps:GetChildren()
local Title = game.StarterGui.MapSelector.Title
local spawns = game.Workspace.Spawns:GetChildren()
local status = game.ReplicatedStorage.Status
local start = game.Workspace.Start
ti = 0
while true do
start.CanCollide = true
ti = 16
repeat
ti = ti -1
status.Value = "Intermission: "..ti.. "s"
wait(1)
until ti == 0
local randomMap = maps[math.random(1, #maps)]
randomMap:Clone().Parent = workspace
current = randomMap.Name
status.Value = "Chosen game is "..randomMap.Name
wait(5)
status.Value = "Loading game!"
wait(2)
local plrs = game.Players:GetChildren()
for i = 1, #plrs do
local randomSpawn = spawns[math.random(1, #spawns)]
plrs[i].Character.HumanoidRootPart.CFrame = CFrame.new(randomSpawn.Position)
end
status.Value = "3"
wait(1)
status.Value = "2"
wait(1)
status.Value = "1"
wait(1)
status.Value = "GO!"
wait(1)
start.CanCollide = false
ti = 61
repeat
ti = ti -1
status.Value = "Time Left: ".. ti.."s"
wait(1)
until ti == 0
for i = 1, #plrs do
plrs[i].Character.HumanoidRootPart.CFrame = workspace.SpawnLocation.CFrame + Vector3.new(0, 10, 0)
end
workspace[current]:Destroy()
end

1 comment
I understand, but I don't know how to do it