Okay so this is just some basic gui stuff but I ran into a error.
Here's what I have so far:
local Player = script.Parent.Parent.Parent.Parent.Parent local Opened = Player.PlayerGui.GameBeta.HoldingFrame.Alliances.Opened function onMouseButton1Down() script.Disabled = true if Opened.Value == true then Opened.Value = false print("Closed") elseif Opened == false then Opened.Value = true print("Opened") end script.Disabled = false end script.Parent.MouseButton1Down:connect(onMouseButton1Down)
I am using a bool value I know that. I can't seem to find the error here currently all I want it to do is print in the output.
Thank you!
Remove script.Disabled = true
, as it stops your script from running, therefore stopping your function from doing anything. Remove script.Disabled = false
also, because it is redundant.
I am actually still having trouble,
script.Disabled is removed and I have this
local Player = script.Parent.Parent.Parent.Parent.Parent local Opened = Player.PlayerGui.GameBeta.HoldingFrame.Leaderboard.Opened function onMouseButton1Down() if Opened.Value == true then Opened.Value = false print("Closed") elseif Opened == false then Opened.Value = true print("Opened") end end script.Parent.MouseButton1Down:connect(onMouseButton1Down)
Still not printing anything into the output.