In the first part of this video series on how to create a shooter style video game in Adobe Flash, we created our main characters, made them move, and shoot. In the second part, we animated our characters. In the third part, we animated our background. In the fourth part of the video tutorial series, we added our lives, score, and Game Over.
At this point, we have functional video game, but no sound. So, let's add some sounds.
You can import any sounds that you like. For this tutorial, all add sounds that play during the game, and a sound for when you shoot. To import a sound, go to "file" then "import to library". Choose the sound that you want to import. Your sound will end up in your library.
To have music play over your game, create a new layer. Name it "sounds". Click and drag your imported music from the library to the stage on the first frame of the "sounds" layer. Then go the properties of that frame and loop the sound. To see how to do this, watch the video below.
Now let's add the sound for our shooting. I'll be using a sound that already exists in Flash. Go to "window", "common libraries" and select "sounds". Find a sound that you like and drag it to your library. Rename your sound to "Shoot" in your library by right-clicking on it. Then right-click on the sound in your library and open up the properties for it. Click the "export for actionscript" radio button. The identifier should change to "Shoot".
Now, test your game and enjoy your sounds.