adding threading for multiple colors