i have tried making a button that will change color to blue when its red and green when its blue and red when its green, this is my script so far;
function zozh(PlayerWhoClicked)
if script.Parent.BrickColor == ("Bright red") then
script.Parent.BrickColor = BrickColor.new("Bright blue")
elseif script.Parent.BrickColor == ("Bright blue") then
script.Parent.BrickColor = BrickColor.new("Bright green")
elseif script.Parent.BrickColor == ("Bright green") then
script.Parent.BrickColor = BrickColor.new("Bright red")
end
end
script.Parent.ClickDetector.MouseClick:connect(zozh)
I'm guessing the error is if "if script.Parent.BrickColor ==", does anyone know the correct way to make a if statement to a parts brickcolor?
