PLAYGROUND.Howl = function(app) {
app.loadAudio = function(audio, opts) {
this.loader.add();
let url = this.getPath("sounds").concat(audio,".", this.preferedAudioFormat || '.mp3' )
this.audio = new Howl({
src: [ url ],
format: [ this.preferedAudioFormat || "mp3" ],
autoplay: false,
loop: false,
preload: true
})
this.audio.once('load', () => {
window.console.re.log('loaded')
this.loader.success.call(this.loader)
} )
this.audio.load()
}
}
PLAYGROUND.Howl.plugin = true
new PLAYGROUND.Application({
smoothing: true,
loaded: false,
preferedAudioFormat: "mp3",
create() {
/* things to preload */
this.loadImage("rejects","orientation")
this.loadAudio("UR-FullExtreme-Voice") // Audio file
this.loadData("cuepoints")
},
then on a State....
create: function() {
....
this.soundId = this.app.audio.play()
...
But does not play( well it says its playing but I hear no volume) on Android 5.1 browser
create: function(){
....
var a = document.body;
a.addEventListener('touchstart', () => {
// window.alert('ok')
window.console.re.log('clicked');
try {
this.soundId = this.app.audio.play()
} catch (e) {
console.re.log(e)
} finally {
console.re.log(this.app.audio.playing(this.soundId));
}
})
But no go. Can you give me some advice here on how to workaround this Android 5.1 bug....?