Override Default Door Sounds

Ask about mapping, UDMF, using DoomBuilder/editor of choice, etc, here!

Moderator: GZDoom Developers

Forum rules
Before asking on how to use a ZDoom feature, read the ZDoom wiki first. If you still don't understand how to use a feature, then ask here.
User avatar
Hindsight2020
Posts: 261
Joined: Wed Mar 20, 2013 3:29 am
Location: Indiana, USA

Override Default Door Sounds

Post by Hindsight2020 »

Okay, I feel like this should be simple enough, but I can't seem to find any info on it.

Is there a way to override the default door sounds in Doom in UDMF in just one map? If I understand it right, I can override them in the SNDSEQ lump, but that will replace them for the entire game, will it not?

I'm trying to create a game in which the player traverses to different places/times and to have the same sounding doors in a creepy hotel as for a futuristic moon base, doesn't make sense.

To go further, I may look at changing the sound at each individual door in a map.

I feel like this is a dumb question...please help.

Thanks for everything ZDOOM forum!
User avatar
Enjay
 
 
Posts: 26402
Joined: Tue Jul 15, 2003 4:58 pm
Location: Scotland

Re: Override Default Door Sounds

Post by Enjay »

SNDSEQ is indeed your answer. You can define a completely new sound sequence with its own name and numeric identifier so that it doesn't clash with or override the default. Then you can make individual doors use that sequence by either placing a sequence changing thing in the door sector or, in UDMF, you can set the sequence directly in the sector properties (make sure you load the WAD or PK3 with your SNDSEQ as a resource in your editor).

I also have a vague recollection that it might be possible to change the default sound sequence for an individual map using MAPINFO but I can't be certain (never done it myself) and I can't check right now.
User avatar
RKD
Posts: 118
Joined: Sat Mar 19, 2022 9:52 am
Operating System: Windows 10/8.1/8/201x 64-bit
Location: Argentina

Re: Override Default Door Sounds

Post by RKD »

Also asking, just out of curiosity. If the idea is to have custom sounds in specific doors from specific maps in UDMF I assume a project in pk3 format would be preferable, adding the files on a "myproject/sounds/" folder, right? How would one call them from there? Is there any line action (or argument) that can do this or should it use a simple script instead?

Excuse if my question is weirdly worded, I just woke up haha
User avatar
Enjay
 
 
Posts: 26402
Joined: Tue Jul 15, 2003 4:58 pm
Location: Scotland

Re: Override Default Door Sounds

Post by Enjay »

You put your sound files in a sounds sub folder of your project, yes, but then you have to define "friendly" names in SNDINFO and then use the SNDINFO defined name in any situation where the sound needs to be called.

So, a SNDSEQ definition will use the SNDINFO names, using ACS, or DECORATE, or ZScript to play the sounds will also need you to reference the SNDINFO name. All of these situations, and more, can play sounds and they all do it via the SNDINFO defined name.

But to get different sounds for different doors, you do pretty much what I said in my post above - define a new SNDSEQ entry (using the SNDINFO names) and then use a sound sequence changer thing in the sector that will move (i.e. the door) or, in UDMF, use the sector properties to allocate the sound to the sector directly.
User avatar
Blue Shadow
Posts: 4903
Joined: Sun Nov 14, 2010 12:59 am
Operating System: Windows 10/8.1/8/201x 64-bit
OS Test Version: No (Using Stable Public Version)
Graphics Processor: ATI/AMD (Modern GZDoom)

Re: Override Default Door Sounds

Post by Blue Shadow »

Enjay wrote:I also have a vague recollection that it might be possible to change the default sound sequence for an individual map using MAPINFO but I can't be certain (never done it myself) and I can't check right now.
Yes. Apparently, a map can have its own [wiki=Map_definition#SndInfo]SNDINFO and SNDSEQ definitions[/wiki].
User avatar
RKD
Posts: 118
Joined: Sat Mar 19, 2022 9:52 am
Operating System: Windows 10/8.1/8/201x 64-bit
Location: Argentina

Re: Override Default Door Sounds

Post by RKD »

I see. The SNDSEQ page in the wiki gives an example of how to give specific sounds to one door, so I think that's pretty much what OP asked for.
Didn't knew you could do that in Doom. Pretty cool :)
User avatar
Enjay
 
 
Posts: 26402
Joined: Tue Jul 15, 2003 4:58 pm
Location: Scotland

Re: Override Default Door Sounds

Post by Enjay »

Yup, it's actually been a feature of ZDoom for over 20 years. I'm guessing probably from around about the time of implementation of the ZDoomHexen format (though it can be done in Doom format maps too).
User avatar
Hindsight2020
Posts: 261
Joined: Wed Mar 20, 2013 3:29 am
Location: Indiana, USA

Re: Override Default Door Sounds

Post by Hindsight2020 »

Blue Shadow wrote:
Enjay wrote:I also have a vague recollection that it might be possible to change the default sound sequence for an individual map using MAPINFO but I can't be certain (never done it myself) and I can't check right now.
Yes. Apparently, a map can have its own [wiki=Map_definition#SndInfo]SNDINFO and SNDSEQ definitions[/wiki].
I did not see that at the very end of the very long list of Map Properites :)
Thank you for the link!

I just have more questions tho; where would I place the local SNDINFO and SNDSEQ lumps? And do I have to call them SNDINFO.whatever and SNDSEQ.namehere? Or does the name really matter if I'm calling it directly in MAPINFO?

Sorry for all the questions. Thanks again!
User avatar
Enjay
 
 
Posts: 26402
Joined: Tue Jul 15, 2003 4:58 pm
Location: Scotland

Re: Override Default Door Sounds

Post by Enjay »

SNDINFO and SNDSEQ go in the root directory of your PK3.

I usually call them SNDINFO.TXT and SNDSEQ.txt (because they are just text files) but you can have pretty much anything after the "." or just calling them SNDINFO without an extension at all.

As for naming when calling them directly from MAPINFO, honestly, I don't know. I've never done it.

Return to “Mapping”