A hack for looping sound in JS has been posted here
stackoverflow
works well for firefox and other browsers:
myAudio = new Audio('someSound.ogg'); if (typeof myAudio.loop == 'boolean') { myAudio.loop = true; } else { myAudio.addEventListener('ended', function() { this.currentTime = 0; this.play(); }, false); } myAudio.play();
Thanks for this might be worth making a plugin to do this <img src="smileys/smiley1.gif" border="0" align="middle" />
Develop games in your browser. Powerful, performant & highly capable.
We were hoping Firefox would just add support for looping (how hard can it be?) but if they don't do it soon we'll add in the hack.