Book Image

Android Game Programming by Example

By : John Horton
Book Image

Android Game Programming by Example

By: John Horton

Overview of this book

Table of Contents (18 chapters)
Android Game Programming by Example
About the Author
About the Reviewers
Platformer – Guns, Life, Money, and the Enemy

Adding sound FX

Adding sound effects in Android is really straightforward. First, let's look at where we can get our sound FX from. If you just want to get on with the coding, you can use my sound FX in the Chapter4/assets folder.

Generating the FX

We require four sound FX for our Tappy Defender game:

  • The sound for when our player crashes into an alien, which we will call bump.ogg.

  • The sound for when the player is destroyed, which we will call destroyed.ogg.

  • A fun sound for when the game first begins, which we will call start.ogg.

  • Finally, a victory whoop-type sound, which we will call win.ogg.

Here is a very quick guide to make these sound FX using BFXR. Grab a free copy of BFXR from

Follow the simple instructions on the website to set it up. Try out a few of these things to make our cool sound FX.


This is a very condensed tutorial. You can do so much with BFXR. To learn more read the tips on the website at the previous URL.

  1. Run bfxr.exe.

  2. Try out all the preset types, which generate...