Custom soundscapes?
Post Reply
Quote
Re: Custom soundscapes?
Posted by ReNo on Tue Dec 7th at 6:41am 2004


First of all, I posted this at VERC already as I've done a fair amount of testing on it and figure that its a bit early in HL2's editing life for anybody to really have looked into yet. At VERC there are a couple of Valve bods who answer some of the less obvious questions, so I'm hoping I'll get a reply from one of them. That said, on the off chance I might as well ask here as well...and I didn't feel right taking my questions elsewhere So on with the problem...

I've been having a little bit of trouble with creating custom soundscapes, and I've come to the conclusion its quite possibly a problem with the engine as opposed to a difficulty I'm having.

I can create a custom soundscape and have it function in the game, however the only way I can do this is by naming the file containing the soundscapes "soundscapes.txt" and placing it in the "...half-life 2 deathmatchhl2mpscripts" folder. This means it is used instead of the soundscapes.txt file found in the HL2 GCF folder, thereby disabling some of the default soundscapes.

The entity helper in hammer gives the following hint that you can create custom soundscape files...

"The name of the soundscape to use. Corresponds to an entry in the soundscapes*.txt file in the hl2acripts directory."

...Note that the typo is in the entity help, I didn't make it myself I assume it to mean the "scripts" folder in your HL / CS:S / HL2DM mod folder, and surely enough if I make the "soundscapes.txt" file with my custom soundscapes in one of those folders, it works. The * in the entity help description suggests you can create your own soundscape files provided their name begins with "soundscapes" - an asterisk is a typical wildcard character right? From my experimenting however, this doesn't seem to be the case.

Anybody experimented with custom soundscapes and found the same problem as me, or found a way around it? Or could any Valve folks give some input on this matter? Soundscapes come across as a very powerful tool and if mappers can't create their own easily for existing mods then its an annoying limitation. Its like materials.txt from HL1 all over again
[addsig]




Quote
Re: Custom soundscapes?
Posted by RabidMonkey777 on Tue Dec 7th at 7:06am 2004


From looking at some of the CS:S soundscapes, the file actually needs to be named soundscapes_mapname.txt instead of just soundscapes.txt - For example, the 'Office' soundscapes are defined in cstrikescriptssoundscapes_office.txt.



Quote
Re: Custom soundscapes?
Posted by ReNo on Tue Dec 7th at 7:23am 2004


Remember the map is actually called cs_office though, rather than office. Looking at the HL2 soundscape files in the GCF it also seems that the filenames don't relate to map names. I tried it anyway, but unfortunately it still didn't work
[addsig]




Quote
Re: Custom soundscapes?
Posted by RabidMonkey777 on Tue Dec 7th at 7:55am 2004


Hmm, good point.

I've been experimenting with this as well and seem to arrive at the same point - I can't get custom soundscapes to work at all. Maybe it is just an engine thing at this moment?




Quote
Re: Custom soundscapes?
Posted by Leperous on Tue Dec 7th at 11:45am 2004


Presumably then you can make your own soundscape_*.txt and reference it somehow in your map (though after searching through the FGDs it would be quite subtle), or maybe it is loaded automatically?



Quote
Re: Custom soundscapes?
Posted by Myrk- on Tue Dec 7th at 12:02pm 2004


Perhaps a command in the compiling references your map to the soundscape txt or a custom vmtb file (or whatever that strange txt variant is that hammer uses- also used to put grass sprites in vast ground areas). [addsig]



Quote
Re: Custom soundscapes?
Posted by Peterix on Tue Dec 7th at 8:58pm 2004


After digging through the SDK, I found that all additional soundscape files must be referenced in "scripts/soundsapes_manifest.txt"

The manifest file with some new soundscape references:

soundscaples_manifest
{
"file" "scripts/soundscapes.txt"

// List additional soundscape files here

"file" "scripts/soundscapes_canals.txt"
"file" "scripts/soundscapes_klab.txt"
"file" "scripts/soundscapes_elab.txt"
"file" "scripts/soundscapes_streetwar.txt"
"file" "scripts/soundscapes_citadel.txt"
"file" "scripts/soundscapes_town.txt"
"file" "scripts/soundscapes_coast.txt"
"file" "scripts/soundscapes_prison.txt"
"file" "scripts/soundscapes_trainyard.txt"
"file" "scripts/my_cool_soundscape.xyz"
"file" "scripts/bogus_soundscape.abc"

}

It seems that it's impossible to define soundsapes on per-map basis right now.
You have to make a new mod or some intelligent map installer, that will be able to parse and/or add to the manifest file.




Quote
Re: Custom soundscapes?
Posted by ReNo on Thu Dec 9th at 12:22am 2004


Thanks a lot for that! I hadn't noticed your reply until I came back to this thread to say that (at last) a couple of people replied on my VERC thread with the very same answer I've suggested that it would be nice for the game to automatically load in soundscape files that match the mapname (eg. soundscapes_map1.txt for the map "map1.bsp"), but it is of course doubtful that this would be implented.
[addsig]




Quote
Re: Custom soundscapes?
Posted by nickster on Thu Dec 9th at 9:47am 2004


Gee, I would've thought that they would've made it easier to use customs sounds with your map.

Oh well, I'm sure somebody will come up with a way to do it eventually. But in the meantime no custom sounds for you!





Quote
Re: Custom soundscapes?
Posted by ReNo on Thu Dec 9th at 2:34pm 2004


Its not custom sounds that is the limitation mate, you can make use of those perfectly fine I think. Soundscapes are used to script what sounds are used in certain areas of the map, what random sounds occur in certain areas, and more. You can still place sounds around with ambient_generics or use the premade soundscapes, but its just not giving you the same degree of control you could have.
[addsig]





Post Reply