For some reason, I can't make my MouseButton1Click script work on a local script. I can't use a normal script because it will trigger to the server and not the client. Here is the code to tell me what I did wrong.
My Locations are under the code.
local slide1 = script.Parent.Parent.Parent
local slide2 = game.StarterGui.TutorialGUI.Frame2
script.Parent.MouseButton1Click:connect(function()
if slide2.Visible == false then
slide2.Visible = true
else
slide2.Visible = false
end
end)
Script.Parent = TextButton
Script.Parent.Parent = Frame1
Script.Parent.Parent.Parent = TutorialGui
game.StarterGUI.TutorialGui.Frame2 = Frame2

5 comments
I changed the slide1 to slide1 = script.Parent.Parent
instead of :connect use :Connect
WideSteal321, that has no affect to the script.
It might not affect now. But it is possible in the future. The former is deprecated in favour of the latter, and because of that the former should no longer be used.
@ViceToxicZ What @incapaxian said.