rocinantealpha

reference / color and style

mix

Blends two colors, or two numbers; amount 0 gives the first and 1 the second.

for i from 0 to 9 [ rect at (i * 40) 0 size 40 300 fill (mix navy gold (i / 9)) ]
what it draws: the whole window, 400 by 300
What the example of mix draws

How to write it

mix first second amount

Gives a color.

mix first second amount

Gives a number.

Related