I'm trying to program the ability for players to be able to teleport to their friends, but have gotten every error I could possibly receive. Breaking it down to its bare bones...
script.Parent.MouseButton1Down:connect(function() local Success, Error, placeId, instanceId = game:GetService("TeleportService"):GetPlayerPlaceInstanceAsync(xxxxx) if Success then game:GetService("TeleportService"):TeleportToPlaceInstance(placeId,instanceId) end end)
I replaced the user's ID with xxxxx but I've basically been testing this with myself and a friend trying to teleport to him in the same game from different servers. However, the most common error I am seeing is an HTTP 403 Forbidden error. What is wrong with the code?

1 comment
I have used server scripts to do it, but gotten the same error. That is not my issue, my issue is the error that comes up(being the HTTP error). Even when I manually used a name in a server script, I still got an error. Can you tell me if there is something wrong with my code? I know that from a server I just add a parameter (placeId,instanceId,game.Players.SomeName)