Recitation 5: Imaginary Creature
Optimus Prime
Optimus Prime is definitely the most welcomed character of the ip “Transformers”. He can transform into a big truck. My project aim to look at how he transforms straightly from the front. The following are the original pictures. I abstracted them.
I referred to the classic toy Transformers masterpiece 10 to design the transform process of my Optimus, it’s quite simple but effective.
Since there are other character that has the same figure as Optimus with different color, so I made use of “Array” so that every time we process the code, it will show a different character, I also used another array to provide their name.
I used the rotate code and for loop during the coding, and they went quite well. I also split every part or limb of the body in different functions, which make adjusting the positions and changing some details more easy.
Here’s the link to my code https://editor.p5js.org/zzrrqqq/sketches/xVfzGGlzX
Reflection:
1.I stored colors and texts in arrays, I used them to randomize the body color and the name of my character, they were really convenient to use. I can simply store information(not only numbers, but also colors, words etc.) in arrays and use them anyway I want. Arrays can also refer to each other. The codes can be much more simple and easy to modify.
2.When I want to start drawing a new pattern individually I will use the codes, using these codes are like creating a new canvas on the original canvas, with the push translate and pop, I can create a pattern while not affecting others, I can also modify it individually without changing other codes to adapt to this change.
3.they are like small canvases on the original canvas, they can split drawing a complicated picture into several modules, one can create and modify each module without affecting others and put them together at will
4.I added parameters to store the picked elements of an array. I also use parameters that contribute to the transforming process.
5.When I apply arrays there’s a radical change, the pattern’s color is fixed before that, but can be changed randomly when I apply the code, making the pattern much more diverse. Also, applying a parameter that keeps changing and use it in my shapes to make them move change my work from a picture into an interactive animation, that’s also a radical change.
Leave a Reply