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

SurfaceGUI script works in Test mode, Not in play mode?

Asked by 8 years ago

Here is my code, It's on a surfaceGUI and teleports the player to another game, Works fine in Test mode as stated.

button = script.Parent 
button.MouseButton1Down:connect(function ()  
plrgui = button.Parent.Parent 
player = plrgui.Parent
id = '411830270' 
game:GetService('TeleportService'):Teleport(id, player)
end)

0
is it a localScript? theCJarmy7 1293 — 8y
0
It was a normal script, I changed it to local would not work in Test mode or Play mode WorldEngine 2 — 8y

Answer this question