I have a localscript that changes the color of the frame when clicked upon. After it is clicked, a new frame will pop-up with multiple options. I want to find out the color of the part clicked on after it showed the new frames.

localscript that changes the color:

local button = script.Parent.Parent.Chocolate		
button.BackgroundColor3 = Color3.fromRGB(255, 151, 151)

localscript that is *supposed *to find the color:

local chocolateCake = script.Parent.Parent.Parent["Step3-Cake"].Chocolate
if chocolateCake.BackgroundColor3 == Color3.fromRGB(255, 151, 151) then
	script.Parent.Parent.Parent.Frame.Visible = true
end

The frame doesn't show when the second button is clicked upon even when the color is the new color.

1 comment

0

Because the program already finished running; you need to check with a MouseButton1Click signal.