Programming simple games in java. The sources are available at http://zetcode.com/tutorials/javagamestutorial/