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

Making Teleport for Game Universe?

Asked by
KAAK82 16
10 years ago

First, do all the places have to be active? (cos I cant activate all, am not BC :() Second, Could I do a Gui Button instead? Third, how would I make a proper Script that would Teleport a person to the Place that the Button was Clicked...

function onClick(Clicked)
    local player = game.Players:GetPlayerFromCharacter(Clicked.Parent)
    if player then
        game:GetService("TeleportService"):Teleport(156207354, player)
    end
end

script.Parent.MouseButton1Click:connect(Clicked)

this is my Script... am sure there are tons of erros... it doesn't seem to work... but I changed the last line cos I forgot to Change (OnTouch) to (Clicked) so am gonna try it now...

2 answers

Log in to vote
-1
Answered by 10 years ago

Game Universe is still not out/ Well some famous game developers/Scripter have them for beta testing i think? Its not public yet..

0
is it not? I thought it was :/ KAAK82 16 — 10y
Ad
Log in to vote
0
Answered by
Gamenew09 180
10 years ago

You are trying to get the player through an argument that doesn't exist, and universes have been released I used it on my place. Make sure you put this in a LocalScript in the player.

local Button = game.Workspace.Part.SurfaceGui.TextButton -- Change this to the Button in the surface gui in the part.

Button.MouseButton1Click:connect(function ()
    game:GetService("TeleportService"):Teleport(156207354) -- You don't need the player in a localscript.
end)

If this helped, please vote me up and accept me as the answer.

Answer this question