CPSC 220 Assignment 5
Hash Table
Due Before Class on Friday, November 6th

In this assignment you will explore how using a hash table to organize objects interacting in a simple 2D game affects performance as measured by the number of frames rendered per second.

Details

You should begin by modifying your game from assignment 4 by adding a fifth enum field for collision detection using hash tables. When the game is set to use this collision detection method it should function the same as with the other collision detection methods. The difference is that objects should be added to a hash table object of a class that you create. You can use whatever hashing function and collision resolution method you would like, but you should be able to justify your choice during your in-class demo.

Your game must also include original sound. That is, nothing downloaded from the internet. The sound can be in the form of background music or sound effects in response to in-game events (or both). You can use Audacity to edit sounds that you record or MuseScore to create sounds. Your game should also turn all sound off when images are turned off for testing purposes.

Your game should also include something new that improves the game in addition to the above requirements. Be prepared to demo your game in class on Friday including an asymptotic analysis of and the number of comparisons when using the different collision detection algorithms.

Hand In: Tar and email your code to your instructor with a subject of cpsc220 assign 5 before class on Friday, November 6th.