When I test out my game in Studio, it seems to work fine but then I play the game on the client via the website, the GUI's don't seem to change when I click on them. And yes, they are text Buttons and nothing else.
local Button = script.Parent Frame = script.Parent.window2 hide = script.Parent.open lhide = script.Parent.open function onClick() if lhide.Visible == false then lhide.Visible = true elseif lhide.Visible == true then lhide.Visible = false end end function onClick() if Frame.Visible == false then Frame.Visible = true elseif Frame.Visible == true then Frame.Visible = false end end function onClick() if hide.Visible == false then hide.Visible = true elseif hide.Visible == true then hide.Visible = false end end Button.MouseButton1Click:connect(onClick)
Everytime that you make a new function named onClick() it will overwrite the other ones. That means that the first two functions are basically useless.
Try putting the code in a LocalScript. When you run the game in the studio, it all runs on your computer locally, so Scripts and LocalScripts act the same. When it is uploaded, the game runs on the server, which is different.
Also, Here is a much cleaner version of your code.
local Button = script.Parent function onClick() for i, v in pairs(Button:GetChildren()) do if v.Visible == true then v.Visible == false else v.Visible == true --If it isn't true, it has to be false. end end end Button.MouseButton1Click:connect(onClick)
If you don't know how to use v in pairs, YOU MUST LEARN RIGHT NOW BECAUSE IT IS THE BEST THING IN LUA!!11!!1!!!one!!!1!!!! jk