Im making a game and if somewone touches the TextButton It will teleport them to a part how can i do this?
✓ ANSWER ACCEPTED
How would i make a TextButton onclick teleport somewone to a part?
1 answer
✓ Accepted answer
MouseButton1Down, game.Players.LocalPlayer, MoveTo(), etc.
script.Parent.MouseButton1Down:connect(function()
game.Players.LocalPlayer.Character:MoveTo(workspace.Part.Position) --change workspace.Part to whatever part you want them to teleport to
end)
This discussion is preserved as it was. New answers, comments, and votes are closed.

2 comments
Are you sure it isnt MouseButton1Click?
MouseButton1Down is also applicable. Click is a 'Down' followed by an 'Up' on the same GUI element, regardless of time passed.