- Home /
Detect state of iOS Mute / Silent Button
Hello,
I need to detect the state of the mute / silent switch on iPhones.
My app narrates a story to the reader. If the mute switch is on, then no audio comes out.
Several beta testers had this happen and they did not make the connection that it was because of the mute switch, so my app looks buggy.
Found this thread, but it was no help. http://answers.unity3d.com/questions/897787/how-to-detect-if-phone-is-in-silent-mode.html
I did find this on the asset store, but there are 0 reviews and I'm nervous about just throwing it into my app. https://www.assetstore.unity3d.com/en/#!/content/56877
I don't understand why there are almost 0 threads on this topic and why the Asset store doesn't have 10 different options to address this. What am I missing?
thanks.
Answer by LilGames · Apr 02, 2017 at 09:56 AM
@DevMan5000 Your app is correctly adhering to Apple iOS Developer Guidelines with regard to the silence switch:
https://developer.apple.com/ios/human-interface-guidelines/interaction/audio/
Your problem lies with your testers, not your implementation.
However, the asset you linked to now has reviews and has been updated, so it may do the trick if you insist on detecting the switch.
Answer by unbreakable3D · Jul 14, 2018 at 04:26 PM
I would suggest a slightly different opinion - completely understand if audio is a core component of your game. LilGames made a reasonable point that you don't want to surprise users, so if you need sound, perhaps a gentle on-screen notification or something at app launch that detects and suggests, "Consider unmuting your device, this app needs sound for best experience."
Your answer
Follow this Question
Related Questions
How to NOT play audio in silent mode with iOS? 1 Answer
iOS background audio getting muted 1 Answer
How do I reduce the CPU load spike caused by playing an audio clip? 1 Answer
Generate Chart with Data 0 Answers
Issues with iPad Audio 0 Answers