Implemented Color Detection functionality