1 decade ago
So yesterday I added all my sound assets to my initial game class so that they begin preloading with Impact's preloader. Since then I've been having issues in IE where the preloader just stops - the white bar stops moving - and never resumes.
Looking in console I will see an error like so:
SCRIPT5022: Failed to load resource: media/music/santa.*
loader.js, line 91 character 4
There are both santa.mp3 and santa.ogg files in the media/music folder.
1 decade ago
I haven't seen this problem in a while and assumed it was fixed. It seems IE9 sometimes refuses to load an audio file for no good reason. Check IE's developer console. The network tab should tell you what happened with this file.
To work around this problem, you can pretend that loading worked fine, even if there was an error. In
, line 61, change this:
loadCallback( path, false, ev );
loadCallback( path, true, ev );
Loading in IE should then work fine, but Impact will not be able to tell you if there was a real problem (i.e. 404) with loading a sound file, so you have to be careful with typos in path name, or check the browser's network tab for problems.
I get this problem now with Visual Studio Express 2012 when running in the Surface simulator after rotating the screen. For some reason I've yet to discover, Impact throws 'Failed to load resources /media/music.mp3' (all sound fails). Removing the check keeps the game running, but without sound (the current track loops until the end before stopping).
i get this once in a while with ie10 and ie11 still. sigh.
Page 1 of 1