I'm making a system where there's a start place (the lobby place) and the game place and when somebody dies in the game place, they will teleport back to the lobby place. I tried making a script for this but it doesn't seem to work and my script analysis/output isn't telling me anything:
game.Players.LocalPlayer.Character:WaitForChild('Humanoid').Died:connect(function()
game:GetService('TeleportService'):Teleport(2094965912)
end)
Can someone please tell me what's wrong?

4 comments
use a remoteevent
Make sure that the script is in a correct place. And make sure that the character has loaded.
It's a localscript in Workspace, should it be somewhere else?
the player variable is missing