Hello, can someone please make me a quick script that I can paste into the TextButton?
Image: https://imgur.com/gallery/pJflVIG
If you see this, this script is for a open and close script (so 2 different text buttons not just one since it’s easier to do a open and close.
Put this inside of the Open Button:
local Frame = script.Parent.Parent.Frame — Replace Frame with the name of your Frame. script.Parent.MouseButton1Click:Connect(function() if Frame.Visible == false then Frame.Visible = true end end)
Put this inside of the Close Button:
local Frame = script.Parent.Parent.Frame — Again, replace Frame with the name of your Frame. script.Parent.MouseButton1Click:Connect(function() if Frame.Visible == true then Frame.Visible = false end end)
Note: Put these 2 different scripts in a LocalScript inside of the Open and Close buttons. Put the open script in the open button and put the close script in the close button.
I hope this helps even though I couldn’t fit your requirements!
The fastest way is to make use of this script:
script.Parent.MouseButton1Click:Connect(function() TargetFrame.Visible = not TargetFrame.Visible end)
Note that TargetFrame would have to be changed to your frames local/path.