Android app stops background music
My android app made with unity 5.3.6 pausing background music. I start play music with some player on my android device, but when I launch my app, after splash screen that music stops, and only music from the game starts and continue playing. This happens on different devices. How to solve this problem?
Answer by Racsoth · Nov 22, 2016 at 03:40 PM
Breaking news: the issue is fixed in 5.4.3f1. Now, in PlayerSettings (Android) you'll find a checkbox named "Mute Other Audio Sources". If unchecked, the game won't stop external audio when run. I've tried it and it works (haven't checked it yet with the checkbox checked).
I'm still missing, however, a way to "duck" the external audio when some audio from the game plays (so the external audio volume is lowered, then the game audio plays with full volume and finally the external audio volume is restored). If someone finds about that little piece of the puzzle, we'd finally be done with this :)
Answer by nesta219 · Aug 26, 2016 at 04:16 PM
I have this problem as well. Been looking for a solution but no luck so far.
Here is some update, looks like fixed, have you tried? https://issuetracker.unity3d.com/issues/apps-without-audio-stop-the-external-audio-sources-on-android
It says fixed in 5.3.7 but I'm still getting the issue in 5.4.*
Same problem here. If anyone finds a solution, please post it here. Thanks.
I forgot to mention: this happened after I updated to Unity 5.4.0f3. I was using an older version until yesterday, and the problem was the inverse: if Android music was playing when I ran my game, the game wouldn't play any audio.
Answer by Vinicios-de-Lima-Clarindo · Sep 13, 2016 at 08:08 PM
HI peoples in Update 5 beta 3 (5.5.0b3) this issue has been fixed im using and testing the new loading image changer its amazing
Thanks a lot for the heads up. Just in case you have time to test: what if you play a sound in unity while Android music is playing? Does the music "duck" (volume goes down, then the sound plays and then volume goes up again), or does it simply plays at the same time that the background?
@Racsoth @nesta219 @Sempe4 @Vinicios-de-Lima-Clarindo
I installed latest 5.5.0B4 build but issue is not resolved. Did any of you were able to resolve this.
I haven't tried updating yet, as I want to bring my project to a stable status before risking breaking something when updating to a beta version. $$anonymous$$aybe I can try to install the beta update in parallel with my current Unity version, but I've never done that before (sounds easy, but given how frameworks sometimes break over anything, I'm pretty conservative with them).
Answer by techshaman · Oct 27, 2016 at 03:27 PM
Any update on this? This question is a bit old, doesn't have an answer, and I am running into this issue on the latest version of Unity (5.4.2)
To reiterate, by default it appears the opening my android app will pause any music playing in the background (from Spotify, for example). Is there a way to prevent this from happening?
I have not yet been able to resolve this issue, unfortunately. I will absolutely update this post if I do find the solution.
Answer by JustBecauseGames · Nov 03, 2016 at 03:53 PM
I have the same issue. Hoping a solution is found! This is a pretty big deal for me as I would like to allow the user to play music while using my app.
Your answer
Follow this Question
Related Questions
Unity Sound Glitched up (in 2D) 0 Answers
Sound Game (wave) 0 Answers
spectrum of microphone 0 Answers
Detect notes playing with microphone 0 Answers
Unity Android no sound 0 Answers