Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

How do I make a GUI button teleport you to another place?

Asked by 9 years ago

Dear reader, Hello robotfan200 speaking! I am just learning how to script. But I have a map and the main menu has a button that will be used to teleport someone to another world, place, map, whatever you want to call it. But I cant figure out how to make it that way... Please Help! From the owner of: RoFa Development (A future ROBLOX game development group)

3 answers

Log in to vote
0
Answered by 9 years ago

Show me what you have so far.

0
Comment things like this, not answer. alphawolvess 1784 — 9y
0
Sorry jefftran60 5 — 9y
Ad
Log in to vote
0
Answered by 9 years ago

Never Mind! I figured it out!

Log in to vote
0
Answered by 9 years ago

Here is how you would do it from a localscript. Place a localscript inside the TextButton.

local self = script.Parent;
local Player = game.Players.LocalPlayer;
local Character = Player.Character or Player.CharacterAdded:wait();

self.MouseButton1Down:connect(function()
    Character:MoveTo(Vector3.new(0,0,0));-- Change 0,0,0 to your position.
end)

Answer this question