Safari iOS HTML5 AAC WHY WHY WHY

Get help using Construct 2

Post » Wed Jun 13, 2012 11:00 am

[QUOTE=Ashley] You shouldn't have to preload anything just to hear audio.

Are you playing your game in the browser or via PhoneGap or appMobi? If you're just in the browser, it's very difficult to get audio to play at all on iOS: the browser blocks all HTML5 audio unless initiated by a user-input action. That's why pressing a button on the w3schools site plays the audio, but a collision event or something else won't play the sound. On top of that I think in the browser it can only play one sound at a time.
/QUOTE]

Hi,

I've recently just picked up Construct 2 and I've made some small projects to test out its features. It all seems good so far apart from the lack of audio when playing through Safari on the iPads (tested on iPad 1[5.0.1], iPad 2[5.0.1] & iPad 3 [5.1])

I initially started out with a backing music track and a simple sound effect. I've since removed the music track to see if it was able to play the sound effect by itself, but I've still had no luck.

The sound effect is told to play on a button On Clicked event, and the files are within the 'Sounds' folder (there is a .m4a, .ogg and .wav)

Does anyone have any ideas? Everything seems to work fine through Safari on the iMac. Cheers.
B
3
Posts: 9
Reputation: 318

Post » Wed Jun 13, 2012 11:09 am

@TomH : you need to preload the file (play it, in fact, on a user click), pause it at 0.1. Then you can start really playing it when the user do something.Pode2012-06-13 11:09:50
B
33
S
9
G
6
Posts: 709
Reputation: 6,704

Post » Wed Jun 13, 2012 11:36 am

[QUOTE=Pode] @TomH : you need to preload the file (play it, in fact, on a user click), pause it at 0.1. Then you can start really playing it when the user do something.[/QUOTE]

Thanks. I'm preloading it now on the start of layout, but I'm not too sure what you mean by the (play it, in fact, on a user click) part. Are you able to elaborate on that for me please? Cheers.
B
3
Posts: 9
Reputation: 318

Post » Wed Jun 13, 2012 12:02 pm

Got it working through On Start of Layout -> preload, play, stop. I couldn't seem to find the 'Pause' option you mentioned. Cheers.
B
3
Posts: 9
Reputation: 318

Previous

Return to How do I....?

Who is online

Users browsing this forum: DemantDigitalArt, Unconnected and 34 guests