Sound success:

I’ve introduced the ambient track with a loop into my scene, the set up was fairly complicated in my games init function I’ve added a setTimeout function so that the sound plays after the game has loaded the sound file. At first the sound didn’t play and it was throwing up an error that the file was not there. After some debugging I found that the file had not finished loading before it was called to play.

My next task is to introduce volume control and a play/pause toggle button and fix this bug.

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s