I thought this would be a great addition to the game for the question screen, where the idea was that when the countdown timer got to 10 seconds left an audio file of a ticking clock sound getting progressively louder would play, and then when the time reached zero, a bell sound would go off.
The code worked great on a desktop, but there are some restrictions in the iOS WebKit which prevents it from being used in the game, so I removed it. Specifically:
- iOS blocks a web page from automatically playing a sound via the autoplay attribute in order to save bandwidth (fair enough)
- In order to play the sound, a user action is required to trigger the sound