Skip to Main Content
Unity in Action, Second Edition
book

Unity in Action, Second Edition

by Joseph Hocking
April 2018
Intermediate to advanced content levelIntermediate to advanced
400 pages
11h
English
Manning Publications
Content preview from Unity in Action, Second Edition

11 Playing audio: sound effects and music

This chapter covers

  • Importing and playing audio clips for various sound effects
  • Using 2D sounds for the UI and 3D sounds in the scene
  • Modulating the volume of all sounds when they play
  • Playing background music while the game is being played
  • Fading in and out between different background tunes

Although graphics get most of the attention when it comes to content in video games, audio is crucial, too. Most games play background music and have sound effects. Accordingly, Unity has audio functionality so that you can put sound effects and music into your games. Unity can import and play a variety of audio file formats, adjust the volume of sounds, and even handle sounds playing from a specific position ...

Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Start your free trial

You might also like

Unity Game Optimization - Third Edition

Unity Game Optimization - Third Edition

Dr. Davide Aversa, Chris Dickinson
Unity Game Development Cookbook

Unity Game Development Cookbook

Paris Buttfield-Addison, Jon Manning, Tim Nugent

Publisher Resources

ISBN: 9781617294969Supplemental ContentPublisher SupportOtherPublisher WebsiteSupplemental ContentErrata PagePurchase Link