This teleporting system doesnt work

I have an issue with teleporting players to a selected map.

-- Module Script
-- Varibles
local ServerStorage = game:GetService("ServerStorage")
local Maps = ServerStorage.Maps:GetChildren()
local SelectMap = Maps[math.random(1, #Maps)]
local TeleportsRound = SelectMap.TeleportRound:GetChildren()

-- Module
local GameManager = {}

function GameManager:TelePortPlayersToGame()
	SelectMap.Parent = workspace
	for _, player in pairs (game.Players:GetChildren()) do
		local character = player.Character or player.CharacterAdded:Wait()
		character.HumanoidRootPart.CFrame = TeleportsRound[math.random(1, #TeleportsRound)].CFrame
	end
end



return GameManager

--Server Script
local GameManager = require(script:WaitForChild("GameManager"))
local replicatedStorage = game:GetService("ReplicatedStorage")
local Status = replicatedStorage.Values.Status
local Intermission = 30
local RoundTime = 300


while true do
	for i = Intermission, 0, -1 do
		Status.Value = "Next Round Starts in: " ..i -- Intermission Timer
		wait(1)
	end
	GameManager:TelePortPlayersToGame()
		for i = RoundTime, 0, -1 do
			Status.Value = "Time Left Until The Round Ends!: " ..i -- Round Timer
			wait(1)
		end
	end
1 Like

“Why won’t these scripts work?”

What doesn’t work?

“I have an issue.”

What issue do you have?

Scripting support is a voluntary service by the community, but then you should also put some effort into it.

2 Likes

I fixed it now sorry for a horrible title.

1 Like