In this program we used Max Msp. We started off by programming the main part of the game, which is the shaking of the money tree. While we programmed, we discovered that we did not have enough time to let the users grow the tree, so we just took a step back on our goal and made the game involve only the shaking of the tree.
Here is a screenshot of our code. First we captured the user and the background, then we subtracted the background and inverted colours so the user's silhouette is black.
However, we later realized that we wanted to detect collision with colour. This means that we wanted the tree's blob to be grey, and the user's blob to also be grey so when the two collided the overlapping grey (which would be black) would be detected. So this is what the final code for background subtraction looks like.
We imported the image of the tree that we drew in illustrator, as well as the money, and the image of the tree once it snaps in half.


Here is our code for making the animation of the tree.To make the tree move back and forth, we animated the image using if statements. If the user’s blob intersects the tree’s blob by more than 150, then the image is moved one pixel to the left. Otherwise it goes back to its original position.
Here is our code for animating the money.
To get a good idea, here is the framework we drew to show the interactions and results of the different objects in this project.
We thought about what sort of feedback we needed to use to let the users know how they are doing.
We created a health bar and text that lets the users know how much money they received. This is what the final product looks like.
Working on this project encouraged us to think about embodiment; to ask ourselves "How can the user interact with a tree as they might in the physical world?" We thought it was realistic to make the user bump/shake the tree, so we programmed our project that way. After testing the collision detect by ourselves, we also discovered we had to give users feedback and allow them to see their own silhouette on the screen so they knew what position they were at.






