In simple terms, when you follow your friend into a universe by pressing the join button on the website, you get sent to the start place. This script teleports them into the place that their friend is in as soon as they join the start place.
local TeleportService = game:GetService("TeleportService")
local Players = game:GetService("Players")
Players.PlayerAdded:Connect(function(player)
local followId = player.FollowUserId
if followId and followId ~= 0 then
local success, error, placeId, jobId = pcall(function()
return TeleportService:GetPlayerPlaceInstanceAsync(followId)
end)
if success then
TeleportService:TeleportToPlaceInstance(placeId, jobId, player)
end
else
print("Player isn't following someone")
end
end)

3 comments
ask the discord
Which line is the error on?
Line 11