Adventure Game Studio

AGS Support => Beginners' Technical Questions => Topic started by: RyanPiezo on Wed 23/07/2008 20:08:50

Title: Background music will not play (SOLVED)
Post by: RyanPiezo on Wed 23/07/2008 20:08:50
Hi, I am at my wits end, please help. No matter what I try I can't get my background music to play. it is in the music folder labeled as MUSIC0.MP3. It won't play automatically on startup, I can't get it to work with the PlayMusic(0) command or the PlayMP3File("MUSIC0.MP3"). I have tried both of those scripts on room load seperately and both of them together and still nothing. I have tried the filename in caps and not in caps incase it was case sensitive. I can't think of anything else to try. Please help?
Title: Re: Background music will not play
Post by: LeChuck on Wed 23/07/2008 20:33:33
Try rebuilding the VOX file(s), go to Game -> Rebuild VOX files.
Title: Re: Background music will not play
Post by: ElaineMc on Wed 23/07/2008 21:41:28
I had a similar problem with an MP3 file-- turned to be either corrupted or in an odd format, but I didn't figure it out until I tried to open it in a regular player.

This probably isn't what's going on here, and you may already have checked for it, but thought I'd throw it out there, especially if all other sounds / music play properly.
Title: Re: Background music will not play
Post by: LimpingFish on Wed 23/07/2008 22:36:03
It could be a conflict between the AGS engine and any media players you may have set up to play mp3 files. I had a similar problem with mpeg video files. AGS wouldn't play them, because fddShow was busy trying to decode them at the same time.

Check and see which media player is configured to open MP3 files when you double click on them.
Title: Re: Background music will not play
Post by: Makeout Patrol on Wed 23/07/2008 23:02:04
You know, I had similar problems when adding music in my game, although it never occurred to me to report it. It fixed itself when I quit the editor, opened it again, and rebuilt the .EXE.
Title: Re: Background music will not play
Post by: RyanPiezo on Thu 24/07/2008 07:44:25
ok, addition to my previous problem. I tried to look for other programs trying to run the file, nothing. and the whole close, rebuild the exe, nothing. I also just discovered that when I compile the exe it puts a little txt file in with it called "warnings" and it says "(in room 1): Music 1 not found" I have the file named MUSIC1.MP3 and it is in the music folder. any ideas? oh, and chuck i can't seem to find this rebuild vox files option? thanks for the help guys
Title: Re: Background music will not play
Post by: Khris on Thu 24/07/2008 08:00:01
Make sure the file isn't named "music0.mp3.mp3".
Open the folder, then select Tools -> Folder Options... from the menu.
In the View tab, unckeck "Hide extension for known file types".
Title: Re: Background music will not play
Post by: RyanPiezo on Thu 24/07/2008 08:14:34
Khris my man, I had just figured that out not 2 seconds ago and was coming on here to tell everyone that i figured it out, and that i was just dumb all along for having it named *.mp3 haha, but you beat me to the punch. Thanks alot for all the help guys :D
Title: Re: Background music will not play (SOLVED)
Post by: matt on Thu 24/07/2008 09:19:06
the thing you are doing wrong is that you are putting the mp3 file in the music folder but if you use the playmp3 command you need to put the compiled folder.
Title: Re: Background music will not play (SOLVED)
Post by: Khris on Thu 24/07/2008 16:19:58
mawildoer: That's right but wasn't the issue here.