Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community!

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

JavaScript Introducing JavaScript Finishing the Game Adding Animated Characters

will it be possible to add music or sounds to it?

ok i really want to make the game has music and sounds but how? can someone tell me?

1 Answer

Steven Parker
Steven Parker
228,025 Points

Yes! You can embed sound in an HTML document with the <audio> element, and then control it from your script using the HTMLMediaElement interface.

You might enjoy the short HTML Video and Audio course.