Step One: Watch Mary Rose Cook Live Codes Space Invaders from Front-Trends. (The second worst conference name ever?)
Step Two: Fork this gist.
Step Three: Respond to this question in your fork: What is one approach you can take from this Mary's code and implement in your project?
Ultimately I think the vast majority of Mary's code will have to be changed in order to conform to our TDD-driven structure. Her strategy was no doubt designed for speed, but it lacks the clarity or testability of the TDD-driven approach.
However, there are certain specific functions in her code that could likely be easily imported:
- using a conditional on keyboarder.isDown to determine if, how fast, and in what direction the center of the player moves
- using a velocity attribute assigned to the bullet to determine the speed at which the center of the bullet moves
- the general concept behind using the Keyboarder expression to determine when a key is pressed
Step Four: Totally Optional: take a look at some of the other forks and comment if the spirit moves you.