How do I fix a frame going visible randomly?
I am having a problem with a frame changing visibility randomly. For making a game Menu, I want the frame to be invisible when the game launches.
I have done some testing and realized that when I close the game with the frame open(visible), it appears invisible(how it's supposed to be) and if I close the game with the frame closed(invisible), it appears visible at the start of the game.
01 | local Button = script.Parent |
02 | local Frame = script.Parent.Parent.Frame |
07 | if Frame.Visible = = true then |
09 | elseif Frame.Visible = = false then |
13 | Button.MouseButton 1 Click:Connect(onClick) |
I have no idea how to fix this, and it's bothering me very much. If you have a solution, I would be grateful if you would share it with me, thanks in advance.