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

Error in my script?

Asked by 10 years ago
15 m = Instance.new("TextLabel", game.StarterGui.ScreenGui.TextLabel)
16 m.Size = UDim2.new(0, 500, 0, 50) --Make sure to use UDim2, NOT Vector3
17 m.Position = UDim2.new(.5, -500, .5, -340)
18 m.TextColor = (1+,+ 1, 1)  
19 m.Text = "Stuff" --Make sure this is a string
20 m.BorderSizePixel = (1.5)
21 m.BackgroundColor3 = Color3.new(1, 1, 1) --GUIs only accept Color3 values, which range from 0 to 1. To convert other colors to Color3, divide each number by 255. In this case, white is (255, 255, 255) and 255/255 = 1.
22 m.BackgroundTransparency = (1)

The numbers at the beginning of each line represent their lines in the full script, I put + around what's underlined in red.

The script analysis says;

Error: (18, 17) Expected ')' (to close '(' at column 15),got','

What have I done wrong and how do I fix it?

1 answer

Log in to vote
0
Answered by
Goulstem 8144 Badge of Merit Moderation Voter Administrator Community Moderator
10 years ago

You have to use the Color3 scale to set the TextColor property, The Color3 scale takes 3 arguments.. each a number out of 255. Your values would make it white, just so you know.

Fix;

m.TextColor = Color3.new(1, 1, 1) 
Ad

Answer this question