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

How do i make a text button open another one?

Asked by 5 years ago
Edited 5 years ago

So i have this GUI that is needed for my game (Im making a pokemon one) and i need my textbutton to make it so my other textbutton shows up. Once that one shows up i need to make it open another text button. All my other things are sorted. I need this as Roblox Studio's has changed alot now and it forces you to use filtering enabled.

0
You don't need filtering enabled for this at all. Toggling a GUI to open another does not require remotes at all. User#24403 69 — 5y
0
This is very vague, when do you want them to open and can you show us what you've coded so far? TheRighteousBuilder 70 — 5y
0
FilteringEnabled is mostly used for Server-Client communication. Operating with something using one client, and no client-client interaction will not require any remote/bindable functions/events. Instead, just have a script that connects to the TextButton's MouseButton1Click signal. Fifkee 2017 — 5y

1 answer

Log in to vote
0
Answered by
Potaaden -18
5 years ago

Use this

local MainFrame = script.Parent
local CloseDonations = MainFrame:WaitForChild("CloseDonations")
local OpenDonations = MainFrame.Parent:WaitForChild("OpenDonations")

OpenDonations.MouseButton1Click:connect(function()
    MainFrame.Visible = true
end)

CloseDonations.MouseButton1Click:connect(function()
    OpenDonations.Visible = true
    MainFrame.Visible = false
end)
--script for open close gui
--you can change it up to fit your problem

You need to make a main frame and a special close button here is the scripted for that

Ad

Answer this question