ylluminarious Posted September 30, 2015 Share Posted September 30, 2015 I have two sounds that I'm trying to play in a game of mine. They're both using the MP3 codec, but one of them is inexplicably not playing in Safari 9 or Firefox 41.0.1 (Mac OS X 10.10.5). It plays just fine in the most recent version of Google Chrome, 47.0.2522.0 dev, but not Safari 9 or Firefox 41.0.1. I'm not sure why one MP3 sound would play while another wouldn't, when they both load just fine and there are no errors thrown, except in Firefox where it complains about not being able to use a given encoding (which doesn't make sense since it plays one of the MP3 sounds).Here is the sound that plays just fine: http://cl.ly/3u1p3Y3v0X1cThis is the one that doesn't play in Firefox and Safari: http://cl.ly/420O3P2r1P04Here is a demo of both sounds playing: http://cl.ly/231I320F053D. When you open it with Safari 9 or Firefox 41.0.1, you can only hear the jump sound. Any ideas as to what's going wrong here? EDIT: Btw, here's the source code for the demo:var game = new Phaser.Game(800, 550, Phaser.AUTO, "game", {preload: preload, create: create});function preload () { intro_music_key = "intro_music" intro_music_path = "intro_music.mp3" game.load.audio(intro_music_key, intro_music_path) jump_key = "jump" jump_path = "jump.mp3" game.load.audio(jump_key, jump_path)}function create () { game.add.text(320, 100, "Audio Test", {fill: "white"}); intro_music = game.add.audio(intro_music_key); intro_music.play(); jump = game.add.audio(jump_key); jump.play();} Link to comment Share on other sites More sharing options...
chg Posted September 30, 2015 Share Posted September 30, 2015 Random guess, but some players might be confused by the random data at the start of the intro_music.mp3 file -<br /><b>Warning</b>: filesize(): stat failed for Heros_Day_Off.mp3 in <b>/home/teknoaxe/public_html/Music/mobile_direct_download.php</b> on line <b>20</b><br /><br /><b>Warning</b>: Cannot modify header information - headers already sent by (output started at /home/teknoaxe/public_html/Music/mobile_direct_download.php:20) in <b>/home/teknoaxe/public_html/Music/mobile_direct_download.php</b> on line <b>20</b><br /> Link to comment Share on other sites More sharing options...
ylluminarious Posted September 30, 2015 Author Share Posted September 30, 2015 Random guess, but some players might be confused by the random data at the start of the intro_music.mp3 file -<br /><b>Warning</b>: filesize(): stat failed for Heros_Day_Off.mp3 in <b>/home/teknoaxe/public_html/Music/mobile_direct_download.php</b> on line <b>20</b><br /><br /><b>Warning</b>: Cannot modify header information - headers already sent by (output started at /home/teknoaxe/public_html/Music/mobile_direct_download.php:20) in <b>/home/teknoaxe/public_html/Music/mobile_direct_download.php</b> on line <b>20</b><br /> Thanks, I got rid of it. That seems to have solved the problem Link to comment Share on other sites More sharing options...
Recommended Posts