Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Chrome 55 now requires audio to be unlocked by user gestures, fails playing audio on Android in iframe #37

Closed
bobonthenet opened this issue Feb 22, 2017 · 3 comments · Fixed by #306
Milestone

Comments

@bobonthenet
Copy link
Contributor

This issue was added to the Phaser repo but I didn't see it here. It also occurs with apk files created with cocoonjs. The workaround in the Phaser issue below worked for me. Details and workaround are in the link below.

phaserjs/phaser#2913

@NeoHoffa
Copy link

I confirm this happens with the latest build on Android when played through an iframe. I tried the workaround given in photonstorm/phaser#2913 which didn't work.

@AleBles
Copy link
Contributor

AleBles commented Jul 28, 2017

I can fix this but right now I'm doubting between two options. Due to #71 we don't use touch events anymore for chrome but Phaser.Touch contains the logic setup for unlocking audio. Ideally I'd like to patch that, but that would mean we disable Pointer events for chrome and move back too Touch events.

The other option is to port the touch unlock code to the Pointer event (or write something generic) but I'd like to know which solution you guys prefer and way.

Any toughts on this @samme ?

@samme
Copy link
Collaborator

samme commented Jul 29, 2017

I favor keeping Pointer Events if we can (but #32 needs to be fixed too).

So option 2, maybe a generic that handle either event type? It could be moved into Phaser.Input or a (tiny) new class, Phaser.TouchLock.

@samme samme added this to the 2.8.4 milestone Jul 31, 2017
@samme samme removed the help wanted label Sep 23, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants