Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
1

Why is the script statement underlined red?

Asked by 7 years ago
1local frame script.Parent.Parent.Shop
2 
3script.Parent.MouseButton1Click:connect(function()
4    if frame.Visible == false then
5        frame.Visible = true
6    else
7        frame.Visible = false
8    end
9end)

2 answers

Log in to vote
0
Answered by
shakran 23
7 years ago
1local frame=script.Parent.Parent.Shop -- forgot an equal sign :P
2script.Parent.MouseButton1Click:connect(function()
3    if frame.Visible == false then
4        frame.Visible = true
5    else
6        frame.Visible = false
7    end
8end)
0
Ty. ;) SheddSky 11 — 7y
Ad
Log in to vote
0
Answered by
Tomstah 401 Moderation Voter
7 years ago

An underline in red simply means a syntax error. Just because I didn't really like that the last answer didn't really say anything about it, I'll mention that you can toggle "Script Analysis" in View and it'll define errors for you and explain what's going on. Another thing is you can hover over text with red underlines and it'll describe the problem, somewhat.

Answer this question