So I have a script in my GUI that detects a script in the workspace that if disabled, makes the GUI disappear. However, this just breaks the game instead. Anyone see why?
repeat wait() until game.Workspace.Lights.Sequence.Script.Disabled == false -- This will keep the code from continuing until LoadVal is disabled.
-- Below is what you want to happen when it does.
script.Parent.BackgroundTransparency = 0.1
script.Parent.TextButton.TextTransparency = 0.1
wait(0.1)
script.Parent.BackgroundTransparency = 0.2
script.Parent.TextButton.TextTransparency = 0.2
wait(0.1)
script.Parent.BackgroundTransparency = 0.3
script.Parent.TextButton.TextTransparency = 0.3
wait(0.1)
script.Parent.BackgroundTransparency = 0.4
script.Parent.TextButton.TextTransparency = 0.4
wait(0.1)
script.Parent.BackgroundTransparency = 0.5
script.Parent.TextButton.TextTransparency = 0.5
wait(0.1)
script.Parent.BackgroundTransparency = 0.6
script.Parent.TextButton.TextTransparency = 0.6
wait(0.1)
script.Parent.BackgroundTransparency = 0.7
script.Parent.TextButton.TextTransparency = 0.7
wait(0.1)
script.Parent.BackgroundTransparency = 0.8
script.Parent.TextButton.TextTransparency = 0.8
wait(0.1)
script.Parent.BackgroundTransparency = 0.9
script.Parent.TextButton.TextTransparency = 0.9
wait(0.1)
script.Parent.BackgroundTransparency = 1
script.Parent.TextButton.TextTransparency = 1
Cheers,
Michael

2 comments
Is the script that is checking this a localscript? Are you attempting to make the code happen when the script is disabled or not disabled?
Both scripts are standard scripts.