Scripting HelpersARCHIVE
A little piece of Roblox history. Preserved for everyone, one question at a time.Read about the archive →
✓ ANSWER ACCEPTED

Why does this local script not change the color of a frame?

script.Parent.MouseButton1Click:Connect(function()
	script.Parent.Parent.Parent.Background.BackgroundF.BackgroundColor3 = script.Parent.Parent.Parent.Background.BackgroundF.BackgroundColor3(131, 116, 208)
end)

This Local Script is inside a TextButton inside a ScreenGui inside of StarterGui. There are no errors that it says.

What I want it to do is change the color of a Frame, inside a different ScreenGui in StarterGui, to RGB color 131, 116, 208 (this color is a pastel purple)

1 answer

✓ Accepted answer

Color3's R, G and B components, should be 0 - 1 so try this:

script.Parent.Parent.Parent.Background.BackgroundF.BackgroundColor3 = Color3.new(131/255, 116/255, 208/255)

1 comment

0

cool it works

This discussion is preserved as it was. New answers, comments, and votes are closed.