ServerStorage=game:GetService("\083\101\114\118\101\114\083\116\111\114\097\103\101")ReplicatedStorage=game:GetService("\082\101\112\108\105\099\097\116\101\100\083\116\111\114\097\103\101")Players=game:GetService("\080\108\097\121\101\114\115")Maps=(ServerStorage:WaitForChild("\077\097\112\115")):GetChildren()Status=ReplicatedStorage:WaitForChild("\083\116\097\116\117\115")while true do local B=20 repeat wait(1)B=B-1 Status.Value="\073\110\116\101\114\109\105\115\115\105\111\110 \058 "..B until B<=0 Status.Value="\067\104\111\111\115\105\110\103 \077\097\112\046"local H=Maps[math.random(1,#Maps)]:Clone()local t=(H:FindFirstChild("\083\112\097\119\110\115")):GetChildren()local E=t[math.random(1,#t)]wait(5)H.Parent=workspace Status.Value="\077\097\112 \099\104\111\115\101\110\044 \116\101\108\101\112\111\114\116\105\110\103 \112\108\097\121\101\114\115\046"wait(2)for B,H in pairs(Players:GetChildren())do if H.Character and H.Character:FindFirstChild("\072\117\109\097\110\111\105\100")then H.Character.HumanoidRootPart.CFrame=E.CFrame end end B=5 repeat wait(1)B=B-1 Status.Value="\083\116\097\114\116\105\110\103 \082\111\117\110\100 \105\110 \058 "..B until B<=0 B=5 repeat wait(1)B=B-1 Status.Value="\073\110\103\097\109\101 \058 "..B until B<=0 for B,H in pairs(Players:GetChildren())do if H.Character and H.Character:FindFirstChild("\072\117\109\097\110\111\105\100")then H.Character.Humanoid:TakeDamage(2000)end end H:Destroy()Status.Value="\082\111\117\110\100 \069\110\100\101\100\044 \119\097\105\116\105\110\103 \102\111\114 \110\101\119 \103\097\109\101\046"wait(4)end


ServerStorage = game:GetService("ServerStorage")
ReplicatedStorage = game:GetService("ReplicatedStorage")
Players = game:GetService("Players")

Maps = ServerStorage:WaitForChild('Maps'):GetChildren()
Status = ReplicatedStorage:WaitForChild('Status')

while true do

	--Intermission

	local Countdown = 20 -- ten second intermission, make this as long as you want

	repeat wait(1)
		Countdown = Countdown - 1

		Status.Value = 'Intermission : '..Countdown
	until Countdown <= 0

	--Choose the map.

	Status.Value = 'Choosing Map.'

	local ChosenMap = Maps[math.random(1, #Maps)]:Clone()
	local Spawns = ChosenMap:FindFirstChild('Spawns'):GetChildren()
	local RandomSpawn = Spawns[math.random(1, #Spawns)]

	wait(5) -- little pause, make this as long as you want

	ChosenMap.Parent = workspace
	Status.Value = 'Map chosen, teleporting players.'

	wait(2) -- little pause, make this as long as you want

	--teleport the players

	for _, Player in pairs(Players:GetChildren())do
		if Player.Character and Player.Character:FindFirstChild('Humanoid') then
			Player.Character.HumanoidRootPart.CFrame = RandomSpawn.CFrame
		end
	end

	Countdown = 5 -- Starting Round In, make this as long as you want

	repeat wait(1)
		Countdown = Countdown - 1

		Status.Value = 'Starting Round in : '..Countdown
	until Countdown <= 0

	Countdown = 5 -- Game Time, ten seconds so the video isn't long, make this as long as you want.

	repeat wait(1)
		Countdown = Countdown - 1

		Status.Value = 'Ingame : '..Countdown
	until Countdown <= 0

	--Kill the players

	for _, Player in pairs(Players:GetChildren())do
		if Player.Character and Player.Character:FindFirstChild('Humanoid') then
			Player.Character.Humanoid:TakeDamage(2000)
		end
	end

	ChosenMap:Destroy()

	Status.Value = 'Round Ended, waiting for new game.'

	wait(4) -- little pause, make this as long as you want.

end
