Adventure Game Studio

AGS Support => Beginners' Technical Questions => Topic started by: mouldy on Tue 01/08/2006 10:09:20

Title: music files won't work
Post by: mouldy on Tue 01/08/2006 10:09:20
When I try to play music in a game they just won't play.
I move the file to the game file in ags call it MUSIC1 and go to AGS rebuild VOB files and try to make it play then load the game and nothing happens???  ???
Title: Re: music files won't work
Post by: Alynn on Tue 01/08/2006 10:15:35
Ok... well lets start from the beginning...

How are you trying to play the music, with PlayMusic(X), are you putting it in the room editor play music on room load, or from the interaction editor?

Next is music1.xxx in your music folder?

What exactly is that xxx (in other words, what file extention are you using), for instance, if it's a MID it is put in the executable, not a vox file.

The answers you provide will help determine an answer for your conundrum.
Title: Re: music files won't work
Post by: Gilbert on Tue 01/08/2006 10:17:38
1. What format was the file in? MIDI? MOD? XM? MP3? OGG?
2. Where did you put it? It should first be put in the Music folder inside your game file's folder.
3. Make sure that when you renamed it to MUSIC1 you didn't really renamed it to MUSIC1 (without the proper extension .mid, .mp3, ... etc.) and not something like MUSIC1.mp3.mp3 (if the stupid default "hide known extension" option for your file manager was checked).
4. What command did you use to play the music? Set it as the bg music of a room, or played it via PlayMusic(), etc. ?

Edit: Alynn beated me to it, but I'll just post anyway.
Title: Re: music files won't work
Post by: mouldy on Tue 01/08/2006 10:22:16
I tried to play the music files in both mp3 and WAV I tried to play them on room load that failed, then I tried going the the room script and on enter tried to play the music that way but it still won't work  :-[
Title: Re: music files won't work
Post by: mouldy on Tue 01/08/2006 10:23:28
There wasn't a music file in the game folder, so I had to create my own and put it in there but still failure  ???
Title: Re: music files won't work
Post by: Alynn on Tue 01/08/2006 10:29:43
Ok what version of AGS are you using... because the music folder should have been there. Now you said you tried to play as both mp3 and wav... are you just changing the file extentions?

You realllllly need to calm down, collect your thoughts and write out step by step what you did. You didn't even answer half of our questions.

Can you hear the music files otherwise, in other words in some sort of media player? You never stated if you checked anything we mentioned.
Title: Re: music files won't work
Post by: limeTree on Tue 01/08/2006 15:24:41
did you make the folder right away and trayed with music in the folder?
If it is an older version you have to set music in the main folder just like the sound in older versions.
(Go on tehnical announcments and download the latest AGS and you will have music and sound folder.)
Title: Re: music files won't work
Post by: mouldy on Wed 02/08/2006 09:42:50
Yes I play the files on all media players I have my AGS is quite old I'll try downloading the latest one and see if that works.
Title: Re: music files won't work
Post by: mouldy on Wed 02/08/2006 09:47:01
I didn't change the file extensions I tried a variety of files. What I did was I imported the room. Then I put the character in the room that worked and then I tried play music on rrom load put the music in a created music folder in the AGS game file then I put 1 in the play music on load and then went to rebuild VOB files it showed the music I waited a bit then tried playing it but that didn't work, then I went to the room script done PlayMusic(1); on when the player enters the room, that also failed and I can't make it play music. I also tried putting the music files in the games main folder and done the same but that also didn't work.  :-\
Title: Re: music files won't work
Post by: Alynn on Wed 02/08/2006 10:05:13
Well if you have an old AGS then you don't need the music folder... thats one...

Secondly, the music1.* should be in the game folder.

Third unless it's an MP3 or OGG it doesn't go in a .VOX file if it's a wav or a midi it gets compiled into the executable.

So in the room editor, you have the Play Music on Room Load checked and the number 1 in the text box behind it correct?

Forth, you can't play VOX files...

Fifth, is the vox file in with the executable (in your compiled folder)
Title: Re: music files won't work
Post by: mouldy on Wed 02/08/2006 10:12:00
I tried to put the music in the game file it's a mp3 file so should I try it without going to rebuild VOX files the vox file is in the compiled folder yes I tried both play muisic on room load and the script one but it won't work I renamed the music to MUSIC1 and then tried and still failure should I just try to download the latest one as it may be something with my version?
Title: Re: music files won't work
Post by: Gilbert on Wed 02/08/2006 10:21:20
You didn't answer, what version of AGS are you using?
Title: Re: music files won't work
Post by: mouldy on Wed 02/08/2006 11:22:51
The version is 2.3. I've worked out the problem now I got mp3 put it into the game folder just the name to MUSIC1 rebuilt the VOX files and put play on room load 1 and tried it and it worked :) I've figured out the problem now thanks to everyone that helped me  :D