Hello, In the hope there are still a few map editors around that still know how to do this.
I want to add custom sounds to my map I have worked on this past few months.
I know how to create the .wav sounds and add them to my SND folder of the map editor
and select the custom sounds by adding an "event" then properties, select sound and at the bottom of the list you see custom, i go to custom and select my sound that I added and it works.
BUT only while using the map editor, I would like to know or what I need to do next so that after running my map on a server everyone hears the custom sounds as well.
So there it is, I know how to add sounds to my map, but need to know what i'm not doing
so that the sounds also work on a dedicated server.
There can be problem that this custom sound is not only packed with your map, so you can try to unpack your mapfiles with Total Commander, copy your files (including folders) to unpacked map and pack again by total commander (WCX plugin)
GoGs wrote:
If you dont know how extract *.dat rename *.dat to *.cbf then use CBF plugin
Or you can assign *.dat also to WCX plugin. Ehm, did you mean WCX plugin, isn't it? So use the same way like with cbf file, both can be opened without any renaming.
I did check my dat file as well by renaming it to .cbf and using TC to open the file
and yes my sound files are there.
Is there anything else I am missing? I have done everything already thats in the replies.
there must be 1 more thing I am over looking.
cheers
P.S. Custom sounds can only be .wav and not .ogg I tested it with .ogg and the map crashes.
you can replace .ogg sounds with custom sounds but not add new .ogg sounds.
techno wrote:
P.S. Custom sounds can only be .wav and not .ogg I tested it with .ogg and the map crashes.
you can replace .ogg sounds with custom sounds but not add new .ogg sounds.
Can be ogg but you need read specification.
If i remember good: 22000Khz, mono, (quality dont remember but you have in download section ogg converter)
Why your sounds not working Don't know. I have the same problem... But silent bob make a map with external sound maybe he remember what he done.
I know it can be done, the map Detroit_Beta_1 has 2 custom sounds I can hear
Police scanner , police car siren, But it's been a while and the creator of that map
doesn't remember how it was done. also I cant extract the map .dat file
says it's corrupted but the map still works in the game.
I have added a link to the map if anyone else wants a look.
http://www.vietcong.info/portal/downloads.php?id=40
Also if anyone can extract & re-zip the .dat file for me then I might work it out
by looking at the data and scripting.
Sound can only be .wav if adding the sound with the Ptero sound editor
open The editor>Editor>Sound Editor is where you find the option.
add your sounds to the SND folder in your map and you will see that the Sound Editor
will not show any sounds in the list unless it's .wav
the YouTub vid show all details
if anyone knows of another map with a custom sound ""not modded sounds""
could you let me know.
Custom sound is a new sound file added to the map.
modded sound file is a file that already exists in the game but was change to make a differant sound
Encase you didnt understand what I meant by must be custom and not modded
I know it can be done, the map Detroit_Beta_1 has 2 custom sounds I can hear
Police scanner , police car siren, But it's been a while and the creator of that map
doesn't remember how it was done.
Thanks for that LDC-78, Sorry I thought you said you don't remember on that other forum I started from. my bad.. I will try this tonight. It's great to finally find other map editors. over the passed 2 or so years I have been making maps and only over the passed maybe 4 months or so I have been getting help from Gogs on the 420 clan. so everything i know apart from gogs help is self tort by making mistakes and finding out my own way of making things work.
I will try this tonight and get back to you.
Thanks heaps for that bit of info.
One other thing to ask, if Frog#1 is (sound ID 2380
is there board/post somewhere I can read about more sound id's. I would like to use about 5 custom sounds
OK it's not working for me :) keep hearing frogs lol
I sent the file to you from my forum LDC78 if you don't mind having a look and correcting what i'm doing wrong.
When I get the file back I will re-open it and see how it's done, I will then Make a vid on youtube and post a link here as well to it.
Cheers mate, Custom sounds work perfect now, I re-did my map and all sounds worked perfect. I will make a YouTube vid on this soon and post a link here as well.
Thanks heaps for all your help LDC-78 with this as well.
The amount of time in reading testing editing over and over and never any luck, it's good to know I now have somewhere else to ask for support.
I tried your "add procedure" ,but with OGG files doesn´t worked for me so try to investigate how to do that.
Idea was if all sounds are located in CBF file so also new added sound have to be there.
If someone want to know how...so here is procedure how to add own OGG file to the map (etc. add new radio music)
1./ create SND folder in: LEVELS -> mapname -> DATA -> mapname -> SND
2./ via OGGENCODER convert WAV file (16bit,mono) to OGG file
3./ copy this file to SND folder which you created in step#1
4./ via PTERODON MP EDITOR(TOP menu: Editor -> Sound editor) add new sound (NOTE: IDs of custom sounds starts at 9000)
5./ after you create Event in map with association with your new sound you may to finalize map (NOTE: in this phase sound is NOT hearable in VC1.6)
6./ unpack mapname.cbf file via TOTAL COMMANDER(NOTE:CBF plug-in required)
7./ create SND folder at the same folder level as folders INI and LEVELS
8./ copy file named XSOUND.TXT to this SND folder (NOTE: file XSOUND.TXT is located in vietcong_160.cbf)
9./ create CUSTOM folder in SND folder and copy your OGG file to CUSTOM folder
10./ now you have to edit XSOUND.TXT via NOTEPAD. In this case added sound is music ,so group ID for music is 17
Find line `group_switch 17 (line5180..I think ) . You will see under this line sound commands for each radio music.
You have to add this command line for your new sound: `snd 9000 custom\9000.ogg 100 44100 0 0.1 100
Explanation: 9000 -> ID of sound custom\9000.ogg -> file path 100 -> volume (loudness) (0 to 100) 44100 -> sample rate (5000 to 48000) 0 -> ? (don´t know) (NOTE: but in XSOUND.TXT file you will find exact explanation of commands) 0.1 -> ? (don´t know) 100 -> hearable distance
11./ in the end just repack these folders INI , LEVELS and SND to mapname.cbf file via TOTAL COMMANDER
12./ in this phase you can create server with this map and sound will be hearable for all
READ CAREFULLY:
NOTE: If you placed your new sound to mapname.cbf file it works like a little Addon which is loaded with map at the start of Vietcong 1.6 (reason: all CBF files include maps CBF files are loaded at the start of VC). So you have to be an attention have NOT same ID of sound in more maps. If you will have same ID of sound in more maps ,engine assign new sound to the same ID which is located in the last loaded map CBF file.
Example: We have two maps named A.cbf and B.cbf . In both maps we have new sound with the same ID (but different name of sound). Engine loads CBF files of maps in alphabetical order. As a first is loaded A.cbf and as a second B.cbf. The final result will be that new sound with used ID will be sound from map B.cbf. When you create server with map A.cbf as a new sound will be used new sound from map B.cbf. Pay attention with adding new sounds.
NOTE2: You CAN´T enter different ID of sound. IDs are assigned by editor. If you deleted previous sound ,the next new sound will have again ID 9000. So you have to creat again sound from previous map to obtain next ID (9001) for your new sound in new map.
NOTE3: Simultaneously you have to edit XSOUND.TXT for your new map and file have to contains sound command from previos map and command for new map.(like I said before CBF are loaded in alphabetical order and this valid also for XSOUND.TXT cause it is part of CBF file). This is valid if you want to have more maps with custom sounds on the server.
NOTE4: In folder LEVELS -> mapname -> DATA -> mapname -> SND you may find SND.DAT file. It is better to backup. This file contains IDs of sound(I think ,but not tested yet). If u deleted all custom sounds and dont´wan´t to create them again ,I think it is enough when you just recopy this SND.DAT(from last changes) to SND folder again.
NOTE5: Closely before finalizing map it is possible remove OGG file from this folder: LEVELS -> mapname -> DATA -> mapname -> SND . So you can reduce size of mapname.dat file. This file is required just for adding new sound via Sound editor(Pterodon MP editor). Ones you created event and associated with new sound it is possible to do that.
I tested this procedure for 2 different maps and it worked correctly.
I hope that I wrote everything about that which I know from testing. This procedure have advantages (you don´t need repack DAT file so you will reduce size of map) or disadvantages (carry out about IDs of sounds and it may happen situation that you download new map from some server and if this map will contains custom sounds it will be don´t worked correctly). It´s up to user which one choice is much preferable for his situation.
Ok I finally got a chance to try this but no good.
1./ create SND folder in: LEVELS -> mapname -> DATA -> mapname -> SND YES this is OK
2./ via OGGENCODER convert WAV file (16bit,mono) to OGG file OK all good
3./ copy this file to SND folder which you created in step#1
OK done
4./ via PTERODON MP EDITOR (TOP menu: Editor -> Sound editor) add new sound (NOTE: IDs of custom sounds starts at 9000) No good, editor only can see wav files not ogg files, ""so I made both wav and ogg files and after adding the wav files I removed
the wav file from the SND folder leaving just the ogg files.
5./ after you create Event in map with association with your new sound you may to finalize map (NOTE: in this phase sound is NOT hearable in VC1.6) thats right sound is not hearable but the ogg files still packed up with the map when finalized
6./ unpack mapname.cbf file via TOTAL COMMANDER (NOTE:CBF plug-in required) OK done
7./ create SND folder at the same folder level as folders INI and LEVELS yep done
8./ copy file named XSOUND.TXT to this SND folder (NOTE: file XSOUND.TXT is located in vietcong_160.cbf) done
9./ create CUSTOM folder in SND folder and copy your OGG file to CUSTOM folder done
10./ now you have to edit XSOUND.TXT via NOTEPAD. In this case added sound is music ,so group ID for music is 17
Find line `group_switch 17 (line5180..I think ) . You will see under this line sound commands for each radio music.
You have to add this command line for your new sound: `snd 9000 custom\9000.ogg 100 44100 0 0.1 100 yep done.
Packed back up still no sound.
I did this many ways with ogg files and wav files and even tried including both ogg and wav but still nothing.
could I ask you to make a demo map with nothing in it and with 1 custom sound just so I can extract it and look
at how you did it, I might see or find out what i am not doing
Yes you are right, I am using WavePad Sound Editor and it don't save in the correct format.
it has a save option of only stereo or mono but not as 16bit 32bit or what ever i want.
I used your example sound and yes you are right I can see 9000.ogg file as well in the editor.
meaning WavePad Sound Editor must not be doing the correct sound format
I downloaded a few other programs but not having any luck.
what program do you use to make ogg files?