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

Teleport Button GUI isn't working? [SOLVED] [closed]

Asked by 9 years ago

I've tried using a Local and Server script to make a Teleport button appear when you touch the part. All I get in the output is > 14:33:56 -- TeleportButton is not a valid member of ScreenGui> .

local button = game.Workspace.OtherworldDoor

function onTouch(part)
    game.StarterGui.ScreenGui.TeleportButton.Visible = true
end

button.Touched:connect(onTouch)

EDIT: I found out that moving the code into the GUI's local script makes it work

Locked by HungryJaffer, woodengop, and Spongocardo

This question has been locked to preserve its current state and prevent spam and unwanted comments and answers.

Why was this question closed?