local TeleportService = game:GetService("TeleportService")
function onTouched(hit)
local player = game.Players:GetPlayerFromCharacter(hit.Parent)
if player then
TeleportService:Teleport(54739220, player)
end
end
script.Parent.Touched:connect(onTouched)
Whenever I touch the brick, it's in the process of teleporting, then it stops responding and I crash.

9 comments
Try :TeleportToSpawnByName(placeid, "SpawnLocation", player) Replace SpawnLocation with another name if you want the player to spawn onto a specific spawn
I have no clue for the crash instead.
This is often a problem with the client (AKA, you). It will fix itself eventually, I believe. It has happened to me before, in different games.
I want to teleport to another game, not a spawn location @maquilage
I am having the same exact issue. When i check it out in studio it shows me this in the output. https://gyazo.com/53fb23dffdea62f6444f3fd607a43584
It teleports to the game and the spawn location IN the other game
How would I know the name? I'm using this for a rally place for a war clan.
The spawn location part is optional and has no effect on the teleporting part of it. TeleportService makes your client go unresponsive sometimes for some reasons. I blame roblox and their wonky rushed untested updates.
bump