Teaching
211 F '06
 
Assignments
The Hand In
The Recipes
The World
Set 1
Set 2
Set 3
Set 4
Set 5
Set 6
Set 7
Set 8
Set 9
Set 10
Set 11
Set 12
Set 13
Set 14

Problem Set 6

Due date: 10/19 @ 6pm

Programming Language: Begnning Student Language with List Abbreviations

Teachpacks: world.ss

Problem 0 [5%]:

Find one interesting article from the weeks news on the use of software/computers in society. Summarize the article in your own words with a single 200-word paragraph, as a pair, one playing writer, the other playing editor. Add both the article and the summary in with the rest of your problem set.


The goal of this problem set is to study the design of a small game program. Designing this program will demonstrate how the design recipe scales up to a first interesting program.


The Problem:

Imagine you have become a game developer and your manager poses the problem of developing the first version of a War-of-the-Worlds game, freely named after H. G. Wells's science fiction novel. The purpose of the game is to prevent a UFO from landing on our world and from destroying the last available weapon. Your manager has employed an artist to create a mock-up, which you can see below.

The UFO (see green flying saucer) descends from the sky at a constant rate. As it does, it randomly drops charges (flat tan line below UFO). If any of those bombs hit the last available weapon platform, dubbed AUP, the platform is destroyed and the player loses. The player also loses if the UFO reaches the ground unharmed.

The player controls the AUP (red line with straight line pointing up at bottom), which can move left and right on the ground and shoot straight up. The AUP moves continuously along the ground. Initially, the AUP starts at the left most border and moves from left to right. A 'left or 'right keystroke causes the AUP to change directions. An 'up keystroke, the player can also launch anti-UFO missiles from the AUP. These missiles (vertical yellow lines) go straight up at a constant speed. If any of them hit the UFO, it destroys the UFO and the player wins.

Design and implement the game in a step-by-step, bottom-up fashion. We recommend you first create a UFO that descends. Then add a controllable AUP. Finally add shots and bombs.

You may want to challenge yourself with additional tasks, e.g., (1) accelerate the AUP if the player hits the arrow key of its current direction; (2) ensure that the UFO and AUP never leave the visible field (make your own decision of what you want to do); or (3) add sounds to the game (Mac OS X and Unix should be easy, I don't know about Windows).

Grading: if you don't follow the design recipe all the way, you will inflict a lot of punishment on yourself, because you will spend a tremendous amount of time getting the game to work. In addition, the graders will punish you a lot. You must design your program in "Beginning Language with List Abbreviations."


last updated on Thu Nov 30 11:55:15 EST 2006generated with PLT Scheme