i am trying to make a colourwheel which works by selecting 2 colours first and finally outputting the right color when combining those two original colours. I have got mostly everything working but cannot get the operators to work accordingly, either im doing something wrong and maybe someone could guide me in the right direction?.
I have tried reading up about operators but to no help, can anyone help or at least point me in the right direction ?
this is the function i am having trouble with...
function resultColorFunction() {
if (colorSquareOne === blue || red && colorSquareTwo === red || blue)
{resultColor = purple;}
else if (colorSquareOne == blue || yellow & colorSquareTwo == yellow || blue)
{resultColor = green;}
else if (colorSquareOne == yellow || red & colorSquareTwo == red || yellow)
{resultColor = orange;}
show();
}