This assignment builds on the previous one. Put another graphic (also called a character) on screen. Here's a GSU-styled capital G that you can use, or feel free to use something else. You can even create your own graphic, if you want. Keep this small, no more than 32x32.

Just as the arrow keys move Pounce around the screen, have the w/a/s/d keys more the second graphic.

Movement

For this assignment, you might want to consider the movements as a separate event from the key presses. That is, have the key presses set values indicating the desired movement. Another function can then implement the movement, first checking to make sure it can work. Having the movement in a different function means that you can check for things like collisions first, and reverse the direction if one is detected. Of course, the character might not be able to move. That is, if the character is in the upper-left corner, it should not move either left or up from this position.

You do not have to implement collision detection for this homework, but we will do collision detections soon.

Include a link to the solution on your webpage. Calling it "lab4.html" is a good idea, and put a link on the iCollege submission folder.