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

How can i mix colors with each other?

so i want to make a script that makes a brick color darker each time but i am not sure how to do this. i have looked on the forum but couldnt find anything.

this is the current script i have to color the parts

Part1.Color = Part2.Color + Color3.fromRGB(1,1,1)

i always get an error saying attempt to perform arithmetic (add) on Color3

1 answer

Use Color3:lerp(). It mixes two different Color3s.

local p2c = Part2.Color

Part1.Color = p2c:Lerp(Color3.fromRGB(1, 1, 1), 0.5) -- The second number is how much of the color you want it to be.

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