There’s no reason why it shouldn’t work. How to fix?
wait(2)
local Players = game:GetService("Players")
local TeleportService = game:GetService("TeleportService")
local TARGET_PLACE_ID = x
local playerToTeleport = Players:GetPlayers()[1]
TeleportService:TeleportAsync(TARGET_PLACE_ID, {playerToTeleport})
The only think that could possibly be wrong is the TARGET_PLACE_ID variable. x is undefined, so you need to change it to the id of the place you want to teleport to.
All the scripters I asked say there is no error in the code. I have checked the place id many times it is correct. I can’t open a topic in the bug report category because I’m not a regular member. I do not know what to do.
This is not an issue with needing to enable third party teleports, that error would mean that the game players are being teleported to is not available. “Attempted to teleport to a place that is restricted” means that the target place is either private or not the start place of said game.
I am the owner of this game so whether it is private or not will not cause a mistake. But I tried, made the game public and it still didn’t work. This teleport location is another place of the start place.