<iframe src="https://editor.p5js.org/bettyz-mushroom/full/G43ftojuo"></iframe

For this week, I already had the idea of making my self-portrait face as a funny pattern in mind.
The first step was drawing the hair and face. Before, I set the hair into only two colors, which is orange for odd row odd column, green for even row even column. But suddenly, I recalled the coding train example of tons of balls with random colors blinking, so I was like why not play with the colors using the for statement? I then changed the “b” value for the hair colors and got the gradient-like effect. But for skin color I kept it simple and only used two colors.
I just tried out the checkerboard for statement, now I want to try the same row and same column statements. I decided to let the rows have the same eyes and the columns have the same mouths. For the eyes I used the same constrain technique as before, only added the for loops. For the odd rows I let them move with mouseY and even rows with mouseX.
Later on I realized I can also use an if statement to merge the odd and even number rows, with “if (i2%2 === 1).” And I did the same to mouths, with “if (i % 2 === 0).”
At last I wanted to make some small rotate rectangles in between the background gaps, but I didn’t know how to set the center rotate point, so it failed and acted weird. But it looks like confetti, so I changed the colors to random to make them more like confetti.
I think the hard part was to figure out the rows and columns relationship and i&i2 relationships, and try to use an easier way to merge some of the repetitive parts with %. And while drawing the shapes with i in the coordinates, I have to calculate and try to picture where they will appear.