Custom optional player class sounds?

Need help with your project? Ask here.
User avatar
Herculine
Doom Kitty
Posts: 70
Joined: Mon Feb 22, 2010 3:44
Location: Ohio
Contact:

Custom optional player class sounds?

Post by Herculine » Wed Dec 19, 2012 17:46

I want to make an optional DOOM player class, DoomGirl, and so far I know exactly how to do it except for the sounds. (At this point I only know how to replace all the default player sounds, but I only want the female sounds for the female class.) I can see in the SOUNDINFO lump for GZDoom that there are separate male and female sounds defined, but I don't know how to attach these to my custom class.

Any help on this matter would be greatly appreciated.

User avatar
Blue Shadow
Global Moderator
Global Moderator
Posts: 304
Joined: Sun Aug 29, 2010 6:09

Re: Custom optional player class sounds?

Post by Blue Shadow » Wed Dec 19, 2012 18:15

All I can do is link you to the $playersound SNDINFO command.

User avatar
Herculine
Doom Kitty
Posts: 70
Joined: Mon Feb 22, 2010 3:44
Location: Ohio
Contact:

Re: Custom optional player class sounds?

Post by Herculine » Wed Dec 19, 2012 18:34

That's exactly what I need. Thank you!

User avatar
Herculine
Doom Kitty
Posts: 70
Joined: Mon Feb 22, 2010 3:44
Location: Ohio
Contact:

Re: But why doesn't this sound play?

Post by Herculine » Mon Dec 24, 2012 0:43

After successfully setting up all the sounds for my custom player class, I decided to add jumping and landing sounds to the default player for the sake of continuity. I did this in the SOUNDINFO lump of my wad like so:

$playersounddup player male *land *grunt
$playersound player male *jump dsjump

...with the .ogg files named GRUNT and DSJUMP.

The jumping sound plays just fine, but the landing sound does not play ever. Furthermore, whenever I try to rename the sound the executable gives me warnings that it is either not a valid player sound or that I cannot alter player sounds.

Anybody know what I'm doing wrong here?

User avatar
Enjay
There is no dark side in the moon, really...
Developer
Developer
Posts: 4592
Joined: Tue Aug 30, 2005 23:19
Location: Scotland
Contact:

Re: Custom optional player class sounds?

Post by Enjay » Mon Dec 24, 2012 0:57

Try

$playersounddup player male *land grunt

instead of

$playersounddup player male *land *grunt

However, I would change the name of the grunt.ogg to something else (eg dsgrunt.ogg) simply because *grunt is a player sound name.

Here's an extract from my sndinfo

Code: Select all

$playersound	player	male	*grunt    dsmoof
$playersound	player	male	*land     dsmland

User avatar
Herculine
Doom Kitty
Posts: 70
Joined: Mon Feb 22, 2010 3:44
Location: Ohio
Contact:

Re: Custom optional player class sounds?

Post by Herculine » Mon Dec 24, 2012 1:04

When I try that and then launch the game, I am given the FATAL ERROR warning message: "dsgrunt is not a player sound" and the execution stops.

User avatar
Enjay
There is no dark side in the moon, really...
Developer
Developer
Posts: 4592
Joined: Tue Aug 30, 2005 23:19
Location: Scotland
Contact:

Re: Custom optional player class sounds?

Post by Enjay » Mon Dec 24, 2012 1:18

What happens if you use entries like my SNDINFO (but using your DSGRUNT name)?

User avatar
Herculine
Doom Kitty
Posts: 70
Joined: Mon Feb 22, 2010 3:44
Location: Ohio
Contact:

Re: Custom optional player class sounds?

Post by Herculine » Mon Dec 24, 2012 1:31

Enjay wrote:What happens if you use entries like my SNDINFO (but using your DSGRUNT name)?
Same result. Using DSMLAND as the name, the game loads fine but the sound does not play in-game.

(BTW I'm using GZDoom v1.7.00)

User avatar
Blue Shadow
Global Moderator
Global Moderator
Posts: 304
Joined: Sun Aug 29, 2010 6:09

Re: Custom optional player class sounds?

Post by Blue Shadow » Mon Dec 24, 2012 2:48

Herculine wrote:When I try that and then launch the game, I am given the FATAL ERROR warning message: "dsgrunt is not a player sound" and the execution stops.
That's because $playersounddup requires one of those special player sounds.
Herculine wrote:$playersounddup player male *land *grunt
That will play DSOOF sound when the player lands.


Now, what you want to do is use $playersound with DSMLAND (if that's the sound lump name) if you want it to play something other than DSOOF for the landing sound.

Code: Select all

$playersound player male *land dsmland
If the above doesn't work, then I have no idea what I'm talking about. :P


Edit: Oh, make sure the sound(s) is inside a directory called sounds if you're using zip/pk3, and is(are) out of any markers if you're using a wad.

User avatar
Herculine
Doom Kitty
Posts: 70
Joined: Mon Feb 22, 2010 3:44
Location: Ohio
Contact:

Re: Custom optional player class sounds?

Post by Herculine » Mon Dec 24, 2012 3:00

Okay, it's working perfectly now. Thanks for all the help everyone.

Also, I probably owe you all an apology. I think when I was testing this sometimes I might not have been jumping far enough for the sound to trigger (it plays after longer jumps but not after shorter ones) so at some point here I may very well have been wasting our time so I apologize for my newbness. :roll:

Post Reply

Return to “Editing Help”