Lab assignment: Manipulating Drawing Objects

Start with the code code at here

0. Draw a single Square on the middle left of the screen. Pressing the 'w' and 's' keys should move this up and down. Write the code in the handleKeyPress() method of the Board.java class to do this. We will give you this code here. Replace Board.java in the zip file with this one. You will see what the starting point looks like.

1. Similarly draw a Square on the middle right of the screen. Pressing the 'i' and 'k' keys should move this up and down.

2. Add a smaller square just inside each of the above two squares. It should also move together with the larger square.

3. Add the ability to "shoot" the smaller square across the board, when the 'a' key is pressed for the left player, and when the 'l' key is pressed for the right player

5. Someday, if you want to (but you most likely will not have time today in lab), add the code to "block" the opponents small square coming towards your side, add score, implement on the iPhone/Android, become rich!