Page 1 of 1

How to add multiple unit sounds in efx.pzdat?

Posted: Sat Feb 16, 2019 2:12 pm
by lsnoop
Can anyone explain how to add more movement and attack sounds for a unit and how it was done in VPaulus Sound Redux Mod?

Or is this a big secret?

When I try to add it myself I get missing animations and errors.

Re: How to add multiple unit sounds in efx.pzdat?

Posted: Sun Feb 17, 2019 7:15 am
by maguro
Hi Isnoop,

Having added a few sounds manually, I can say that attack and movement sounds work in a slightly different way. When you add a movement efx, just drop the mp3 for that effect in the movement folder, located in the audio folder of the game. Make sure the efx name of the mp3 matches what you name it in the efx.pzdat file located in the graphics folder. By looking at the names of the other files in the movement folder, you can quickly get a sense of where these names should go in the efx.pzdat file. If there is even the slightest error, typo, etc, the effect won’t work right. Usually any errors should be easy enough to spot though.

With attack efx the same applies except you also need to add a corresponding visual effect to play with the audio effect. These go in the efx folder (I think it’s called efx but I’m not able to check right now) within the graphics folder. The easiest way to do this is to export an existing effect to another location (maybe your desktop). You will want this effect to be similar of to the new effect you wish to add. Example: if you add a light at gun sound specifically for smaller guns like the 37mm etc, you can use the effect for “lightAT” already in the efx folder. If you were to use something like one of the infantry attack files, that will look strange. Anyway, after choosing a file, change the name to the intended new effect name, in this case “37mmAT” or something, then import it back into the efx folder. Again, all the file names (The efx.pzdat script, the mp3 file, and the video file - forgot the actual name of this file) should match up. If so, your new efx should work.
Sorry I don’t have a chance to attach any pics as I’m away from the pc, but If after trying it you still need help, I can add some later. Hope this helps.

Re: How to add multiple unit sounds in efx.pzdat?

Posted: Sun Feb 17, 2019 7:24 am
by maguro
Sorry, I forgot to mention, (if you haven’t done so already) once you start playing around with these files, you’ll want to have everything backed up in case there’s a problem.

Re: How to add multiple unit sounds in efx.pzdat?

Posted: Sun Feb 17, 2019 10:03 am
by lsnoop
Thanks for a comprehensive reply maguro it works now :P

Re: How to add multiple unit sounds in efx.pzdat?

Posted: Sun Feb 17, 2019 11:30 am
by maguro
I didn't know if explanation would be easy to follow but glad it helped in the end!

Re: How to add multiple unit sounds in efx.pzdat?

Posted: Tue Feb 19, 2019 8:58 pm
by Maths
Hi Maguro !
I've tried to add some sounds too for a unit I've created before but I didn't achieved to do what I wanted. My unit is working well, its movement sound is ok but impossible to see neither a shooting animation nor an attack sound. So I would be glad if you could help me in detailing a bit more your process
Thanks in advance !

Re: How to add multiple unit sounds in efx.pzdat?

Posted: Wed Feb 20, 2019 6:54 am
by cw58
Maths wrote: Tue Feb 19, 2019 8:58 pm Hi Maguro !
I've tried to add some sounds too for a unit I've created before but I didn't achieved to do what I wanted. My unit is working well, its movement sound is ok but impossible to see neither a shooting animation nor an attack sound. So I would be glad if you could help me in detailing a bit more your process
Thanks in advance !
The following is an entry for the Panzer IVD from the efx.pzdat file:

Panzer_IVD.png (31,-17) (-31,-18) (,) (,).............. ATlight1 ATlight3 ATlight2.....................tracked_medium1 tracked_medium2 tracked_medium3

The last 3 entries (in italics) refer to 3 audio files found in the folder Panzer Corps/Audio/MoveSfx. But it seems as if you've figured that part out already.
The 3 entries in the middle (in bold) refer to files in 2 different locations. First, there are 3 audio files in the folder Panzer Corps/Audio/AttackSfx. Second, there are 3 graphics files in the folder Panzer Corps/Graphics/Animations.

The names of the attack animations and movement sounds in the efx file need to match files found in those 3 different folders. Another thing to note is that it's not necessary to have 3 different animations or movement sounds; that just adds some variety. Pick out a vanilla unit from the efx file and go look up the listed files in the 3 different folders. I think you'll be able to see how it works. And if none of that makes sense, I'm sure Maguro can clarify it better. :D Good luck.

Re: How to add multiple unit sounds in efx.pzdat?

Posted: Wed Feb 20, 2019 10:51 am
by maguro
cw58 wrote: Wed Feb 20, 2019 6:54 am And if none of that makes sense, I'm sure Maguro can clarify it better.
Nope, I think you pretty much nailed it, cw58. In fact, you reminded me that I wrongly called the animations folder the "efx folder" in my earlier post.
Maths wrote: Tue Feb 19, 2019 8:58 pm My unit is working well, its movement sound is ok but impossible to see neither a shooting animation nor an attack sound. So I would be glad if you could help me in detailing a bit more your process
Thanks in advance !
This sounds a lot like the game is not reading your graphics file in the animations folder. If the graphics file doesn't work properly, neither the sound effect nor the graphic effect will work. From my experience (trial by error mostly) this file affects both sound and graphics. In other words, the sound effect for attack sounds seem to need the corresponding graphic file to work.
I swear I've had all the file names copied and matched for each file and once or twice something didn't work. Even if the graphics file name looks identical sound file, try copying and pasting it again. Then add the new file to the animations folder. It might just solve the issue. Otherwise, following cw58's explanation should get you where you want go.

Hope this is helpful!

Re: How to add multiple unit sounds in efx.pzdat?

Posted: Wed Feb 20, 2019 11:36 am
by Maths
Hi, it finally worked ! I've checked once again the files you both mentioned and all things were ok. So I disabled and re enabled the mod using GME and then it worked. Thank you much ! Your explanations were very comprehensive and clear, so it's great ! Have a nice day !

Re: How to add multiple unit sounds in efx.pzdat?

Posted: Wed Feb 20, 2019 12:16 pm
by maguro
No prob,

btw, just curious about what sound mods everyone is using. I'm thinking about making some new movement sounds for game if time permits.

Re: How to add multiple unit sounds in efx.pzdat?

Posted: Fri Feb 22, 2019 8:31 pm
by Maths
Hi Maguro
Sadly I cannot tell you what sound mods I use ( if only I correctly figured out what you're saying and if only you're actually wondering about sound mods :) ) since I don't use any. I wanted to add existing sounds from other sources to my mod. I'm trying to expand the French Army by adding new units... and maybe create a What If ? path if France hadn't surrendered in 1940

Re: How to add multiple unit sounds in efx.pzdat?

Posted: Sun Feb 24, 2019 11:18 pm
by maguro
Maths wrote: Fri Feb 22, 2019 8:31 pm I'm trying to expand the French Army by adding new units... and maybe create a What If ? path if France hadn't surrendered in 1940
I like your campaign idea. A fresh take on the game and I’m not sure anyone has tried it. Keep us updated on how it’s going :)

Re: How to add multiple unit sounds in efx.pzdat?

Posted: Mon Feb 25, 2019 7:19 am
by Maths
[/quote]

I like your campaign idea. A fresh take on the game and I’m not sure anyone has tried it. Keep us updated on how it’s going :)
[/quote]

Sadly I cannot assure that it will be ready soon, I'll be very busy next weeks but yes I'll keep you updated !