So I’m trying to achieve a teleportation system between my places
But every time i try to teleport i keep getting this one error in my output console which is not allowing me to teleport to a private server
This is the section of the script that is teleporting the players
local function teleportPlayers()
if #list > 0 then
script.Parent.GuiPart.SurfaceGui.Frame.Status.Text = "TELEPORTING"
script.Parent.GuiPart.SurfaceGui.Frame.Status.TextColor3 = Color3.new(1,0,0)
local playersToTeleport = {}
local teleportTime = 0
for i=1,#list do
if game.Players:findFirstChild(list[i]) then
table.insert(playersToTeleport,game.Players:findFirstChild(list[i]))
TransitionEvent:FireClient(game.Players:findFirstChild(list[i]))
else
table.remove(list,i)
end
end
local code = TS:ReserveServer(placeId)
teleporting = true
TS:TeleportToPrivateServer(placeId,code,playersToTeleport)
repeat wait() until #list <= 0
script.Parent.GuiPart.SurfaceGui.Frame.Status.Text = "READY"
script.Parent.GuiPart.SurfaceGui.Frame.Status.TextColor3 = Color3.new(34/255,255/255,20/255)
teleporting = false
end
end
If anyone knows how to fix this problem, please reply i’m in dire need of help!