CyberMax
CyberMax › Answers

Roblox round system: intermission, round timer and winners

Updated 2026-10-17 · Roblox and game developers · by CyberMax

Short answer

Run one loop on the server: wait until enough players are in, count down an intermission, teleport players to the map, run a round timer while checking a win condition, award the winners, then bring everyone back to the lobby and repeat. Publish the state and time left through attributes on ReplicatedStorage so every client's GUI can show them.

Copy-paste code

ServerScriptService/Rounds.server.lua

local Players = game:GetService("Players")
local state = game.ReplicatedStorage -- clients read the attributes for the GUI
local MIN_PLAYERS, INTERMISSION, ROUND = 2, 15, 120

local function setStatus(text, seconds)
	state:SetAttribute("Status", text)
	state:SetAttribute("EndsAt", workspace:GetServerTimeNow() + (seconds or 0))
end

local function alive(list)
	local out = {}
	for _, p in list do
		local hum = p.Character and p.Character:FindFirstChildOfClass("Humanoid")
		if p.Parent and hum and hum.Health > 0 then table.insert(out, p) end
	end
	return out
end

while true do
	while #Players:GetPlayers() < MIN_PLAYERS do
		setStatus("Waiting for players")
		task.wait(2)
	end
	setStatus("Intermission", INTERMISSION)
	task.wait(INTERMISSION)

	local inRound = Players:GetPlayers()
	for _, p in inRound do
		if p.Character then p.Character:PivotTo(workspace.MapSpawn.CFrame + Vector3.new(math.random(-8, 8), 3, math.random(-8, 8))) end
	end
	setStatus("Round", ROUND)
	local deadline = os.clock() + ROUND
	while os.clock() < deadline and #alive(inRound) > 1 do task.wait(1) end

	for _, p in alive(inRound) do
		if p:FindFirstChild("leaderstats") then p.leaderstats.Coins.Value += 50 end
	end
	setStatus("Round over", 5)
	task.wait(5)
	for _, p in Players:GetPlayers() do p:LoadCharacter() end
end

Good to know

EndsAt uses workspace:GetServerTimeNow(), so every client shows the same countdown without the server sending a message each second.

Players who join mid-round stay in the lobby until the next round because inRound is captured at the start.

Roundmoor Round & Match System: Rounds, map votes and teams that never get stuck

from $7

Roundmoor is the full round and match system: lobby, intermission, map and mode vote, fair teams, spawn protection, win checks for four modes, an MVP scoreboard and rewards paid exactly once per match.

Secure checkout · 14-day fix-or-refund if it doesn't work as described (terms)

Questions

How do clients show the timer?

Read ReplicatedStorage:GetAttribute("EndsAt") and display EndsAt - workspace:GetServerTimeNow() every frame.

How do I add map voting?

Run a vote during intermission and load the winning map before teleporting; Roundmoor includes it.

Free: the Roblox Starter Kit

7 free Luau modules (damage, pets, shop formatting, admin audit log, tycoon guards and more) plus 3 free calculators, then 5 short emails with the scripting fixes we see go wrong most often.

You get one email to confirm first. Then the kit, and 5 short emails over two weeks. One-click unsubscribe in every email; we never share your address.

Related answers

How to raycast in Roblox: a gun script the server checksworkspace:Raycast with RaycastParams for a hitscan gun: the client sends aim, the server checks fire rate and Roblox admin commands script with ranks (for your own game)Add :kick, :tp and :speed admin commands to your own Roblox game with TextChatService, a rank check by UserId