We developed an algorithm for changing the direction the leaf is “floating”. If the down arrow is pressed, the y position increases and the x position increases making the leaf go towards the bottom right corner. If the other arrows are pressed, the leaf increases and decreases the x and y positions in the correct direction to change the leaf’s location across the page. When the mouse is clicked, the leaf is given the x and y position of the mouse.
Problems:
While creating our animation, we had difficulty getting the leaf to our desired shape. One way to create a more leaf like image would be to use vertex() and connect multiple points together with noStroke().
No comments:
Post a Comment