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

Making a button open a window on a gui?

Asked by
neopy2 0
10 years ago

Can someone please tell me how to make a GUI button open a GUI.

2 answers

Log in to vote
0
Answered by 10 years ago

I'd probly do something like this;

script.Parent.MouseButton1Click:connect(function() --I use LocalScripts when it comes to the Players
--Gui
gui=script.Parent:FindFirstChild("Frame")
if gui~=0 then
gui.Visible=true
end end) --Something like that

If you do not understand still, then contact me and I'll see what I can do to help.

Ad
Log in to vote
0
Answered by 10 years ago

Like this;

gui = script.Parent.Button
frame = script.Parent.Frame

gui.MouseButton1Down:connect(function()
frame.Visible = not frame.Visible;
end)

Answer this question