CSCI 1321 (Principles of Algorithm Design II), Fall 2007:
Homework 4

Credit

Design 20 points; code 40 points.

Overview

In this assignment you will begin to construct the entities you want in your game in addition to the player. You should probably sketch out classes for all the entities you intend to have, but you don't have to complete all of them for this assignment. Entities that don't move should be relatively easy to do, and you should be able to complete those; you also need to edit the code for your player so that it interacts with these entities in the way that it should. You will also write a replacement for the GameEntityList class in the framework.

Design

The design for this assignment will include descriptions of the classes you will write (one for each kind of non-player game entity, plus the replacement for GameEntityList) and their methods. As before, for the design step you can write skeleton or stub versions of the new classes. You should also look again at your descriptions of classes you wrote for previous homeworks and see if they need to be improved or updated. Remember that I want at least a short comment about every class and every method. As your project gets bigger and more complex, the comments describing classes will become more important, since they help human readers of your code understand how everything fits together.

Step-by-step instructions

Code

For this assignment, you have to write a number of classes, described in the next section (``Classes for this assignment''). This section describes the overall procedure.

Step-by-step instructions

Classes for this assignment

For this assignment you could be writing quite a few classes, but many of them will be similar. The coding job consists of several pieces -- writing your game-entity classes and modifying your player, revising your game setup class so you start out with an acceptable layout of blocks and game entities, and writing your replacement for GameEntityList.

Files and links



Berna Massingill
2008-09-12