2016 November 3,

CS 111: Assignment: Objects

This assignment is intended to help you program with objects. You may work with one partner. Download zombieBetter.py and rename it zombieCustom.py. You will submit this one file electronically, by Monday at the start of class.

First Task: More Zombies

I'd like the simulation to be able to handle more than two zombies. Change the zombies function so that it takes in a positive integer n, and runs the simulation with n zombies. To keep things interesting, these zombies should start with various, randomly chosen positions and velocities. You should not need to alter the Zombie class at all.

Second Task: Panic

Add a "panic button" to the game. When the user presses this button, it teleports the human to a random location in the world, so that perhaps she can spend a few moments zombie-free.

Third Task: A Larger Improvement

The preceding improvements are pretty small. Now let's add a larger feature, that involves alterations to one or more of the classes in zombieBetter.py. I give some suggestions below, but feel free to come up with your own ideas, as long as they are comparable in size and difficulty to mine.

The game would be better with better graphics, that looked like a human and a zombie, rather than the Earth and the Moon. So you might consider getting some better graphics. But this kind of improvmement is not really educational, so it will not earn credit.

Polish and Submit your Work

Don't forget to polish and test your code thoroughly. It will be graded according to these criteria: