Multiple Audio Sources (69943)

Hello!

I have created a fun little arcade space shooter. Towards the end of the game when about to face the final boss, I have set up a fade in/out setup so it fades out of the game music into the final boss battle music. The issue is that during the fade transition when the music is at its minimal, it also fades out the gameplay sounds. So, I created a secondary audio source that plays the music and the camera plays the gameplay sounds. It works nicely. The musics fades and the gameplay sounds continue on.

But, Im getting a message in the log saying that there are two audio sources; that there should always be 1 audio source…is this a problem? Is there a way around my situation that can keep the music volume and the gameplay volume separate without using two sources?

I hope this makes sense. I didnt post code because I hope my explanation said it all.

Thanks!

You can’t have two listeners in a scene (would be like having two microphones hooked up to one speaker.) You can have all the audioSources you like.

It’s probably complaining that a single game object has two audioSources, so it isn’t sure which settings to use. Just put the other audioSource on an empty.