i am making a new sim game gui only, and i'm trying to make windows open and close but it isn't working.
script.Parent.MouseButton1Click:connect(function(Click) script.Parent.Parent.Parent.Stuf.Click:Play() if script.v.Value = false then script.Parent.Parent.Parent.pop1.Visible = true script.v.Value = true else if script.v.Value = true then script.Parent.Parent.Parent.pop1.Visible = false script.v.Value = false end end end)
Getting this in output
11:53:08.180 - Players.Player1.PlayerGui.ScreenGui.Frame.Frame.ImageButton.ButtonDownGui:7: 'then' expected near '='
Dont forget the local part and name it frame
script.parent.MouseButton1Click:connect(function() frame.Visible = not frame.Visible** end)
Fixed