Getting a number from a color
It will be important to get a number and not a color from your color sensor. You don't want the amount of light. You want one of 7 values (black, blue, etc.). The color sensor does output the number associated with the color.