local counter = 5
local players = game:GetService("Players")
local tps = game:GetService("TeleportService")
local placeid = 11726871265
local tpoption = Instance.new("TeleportOptions")
for i = counter, 0, -1 do
script.Parent.Text="Teleporting You back in <font color=\"#FFC900\">"..i.." Sec </font>"
wait(1)
end
script.Parent.Text="Reserving Server"
wait(.5)
local tpoption = Instance.new("TeleportOptions")
tpoption.ShouldReserveServer=true
script.Parent.Text="Teleporting..."
wait(0.5)
tps:TeleportAsync(placeid, tpoption)
this is the code I tried to run but it came and error on teleporting but it worked on script, I wanted to work it on script, how could I
You need to fire a RemoteEvent to get your player teleported. You can use RemoteEvent:FireServer(), and on the 1st parameter of the server, the player is already there: