A11-Adding Music and Sound Effects

On This Page


Overview

The main points of this assignment are to:

  • Add sound effects to your game
  • Add background music to your game

Specifications

Use the techniques we discussed in class to:

  1. Use the techniques we have discussed in class to add one or more sound effects when the player and non-player sprites interact.
  2. In addition, add code to play background MIDI music while your game is running.
  3. Use a subclass of GameCanvas to control your game. The name of this subclass must be GameManager.
  4. Make sure your game has at least two sprites where:
    1. A player sprite moves under player control.
    2. A non-player sprite that moves under its own direction.
    3. Something happens when the player and non-player sprites interact.
    4. Some interaction occurs between the player and non-player sprites and the game world
  5. Make an executable JAR of your program containing all the files described in the section of this document: What to Turn In.

Extra Credit

Adding the following are worth extra credit points:

  1. Briefly demonstrate your assignment to the class. (1 point)
  2. Change the background music in response to events within the game. For example, when the game changes from exploring to fighting. (1 to 2 points depending on the way the transition is handled)
  3. Play MP3 or Ogg Vorbis sounds in your game. This will require a third-party library as Java does not support playing these sounds in its standard libraries. (2 points)

Make certain that your README.txt file describes any extra credit attempted.

Grading Criteria

The instructor will evaluate your assignment using the following criteria. Each criteria represents a specific achievement of your assignment and has a scoring guide. The scoring guide explains the possible scores you can receive.

Some scoring guides have a list of indicators. These indicators are a sign of meeting, or a symptom of not meeting, the specific criterion. Note that a single indicator may not always be reliable or appropriate in a given context. However, as a group, they show the condition of meeting the criterion.

For information on grading policies, including interpretation of scores, see the course information page.

Program Compilation

  • 4: Source code compiles with no errors or warnings
  • 2: Source code compiles with warnings
  • 0: Does not compile or wrong file turned in

Functionality

  • 10: Demonstrates mastery of the assignment
    • Has extra features or demonstrates techniques beyond the assignment
    • Applies concepts from the lesson(s) appropriately
    • Meets all specifications (see above) with particularly elegant solutions
    • No errors encountered during operation
  • 8: Has all the functionality expected of the assignment
    • Demonstrates many techniques from the lesson
    • Meets all specifications (see above)
    • Implementation seems more complicated than necessary.
    • May have one minor error
  • 6: Has most of the functionality expected of the assignment
    • Demonstrates some techniques from the lesson
    • Meets all but one of the specifications (see above)
    • Implementation seems excessively complicated.
    • May have 2-3 minor errors
  • 4: Has some of the functionality expected of the assignment
    • Demonstrates some techniques from the lesson
    • Meets at least 1/2 of the specifications (see above)
    • Implementation seems excessively complicated.
    • May have more than 3 minor errors
  • 2: Serious functional problems but shows some effort and understanding
    • Meets less than 1/2 of the of the specifications (see above)
    • Has a major error or many minor errors
    • Implementation seems very convoluted
    • Demonstrates few techniques from the lesson
  • 0: Does not execute or no specifications met

JAR File Packaging

  • 2: Program runs from the JAR file
  • 1: Program does not run from the JAR file
  • 0: No JAR file submitted

Code Documentation

  • 2: Code is well-documented
  • 1: Code has some documentation errors
  • 0: No apparent attempt to document code

REAME.txt File

  • 2: README.txt file submitted with specified information included
  • 1: README.txt submitted but some information was not included
  • 0: No README.txt submitted

Maximum Score: 20, plus extra credit

What to Turn In

Submit your assignment following the instructions for homework. Create a single JAR file, following the instructions in the section Archive Your Files of How To Submit Homework Assignments, with the following contents:

  1. README.txt file
  2. All of your source code files in the JAR file
  3. All the files needed to make JAR file execute
  4. All the image files
  5. All the sound files
  6. Any other files needed to make the game operate

You must submit all the files needed for your assignment to compile and work correctly. Do not assume that the instructors has any files. Also, do not turn in files that are not part of your assignment, especially ones that do not compile. Your assignment must compile using javac *.java and work as submitted.

Home | WebCT | Announcements | Schedule | Expectations | Course info
Help | FAQ's | HowTo's | Links

Last Updated: May 10 2007 @23:28:05