Facebook Twitter YouTube Frictional Games | Forum | Privacy Policy | Dev Blog | Dev Wiki | Support | Gametee


Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Player Footsteps
RaideX Offline
Member

Posts: 212
Threads: 33
Joined: May 2013
Reputation: 7
#1
Player Footsteps

Hey there. I just wanted to ask if anyone knows where the config entry for the player footsteps are and how they work exactly.

I know where the sounds are located at, but not where the game knows where to get them from (i.e. the config file).

Hope anyone knows.

If you don't draw first, you don't get to draw at all... -The False Shepherd
11-17-2013, 12:12 PM
Find
WALP Offline
Posting Freak

Posts: 1,221
Threads: 34
Joined: Aug 2012
Reputation: 45
#2
RE: Player Footsteps

In the materials.cfg you can set the "StepType" for a material, but there does not seem to be any direct pointing to a file.
a step type could fx be "rock".
I will either assume that the step-types are coded into the core, or that the game is coded to look for that the sound files in the steps folder are named correctly.
fx theres "step_walk_rock.snt", which means that the game might be able to detect on it's own that "this is a step_walk footstep" and that "the type is rock", so if someone writes "rock" as step-type for a material the game might be able to detect it simply because of the naming. I have not tested this myself though so it might just be coded into the source code, in which case you will have to rely on replacing existing step-types with FC.
11-17-2013, 12:46 PM
Find
RaideX Offline
Member

Posts: 212
Threads: 33
Joined: May 2013
Reputation: 7
#3
RE: Player Footsteps

alright, thanks for the answere. Will see what i can do with that.

If you don't draw first, you don't get to draw at all... -The False Shepherd
11-17-2013, 01:16 PM
Find
ExpectedIdentifier Offline
Member

Posts: 234
Threads: 10
Joined: Sep 2012
Reputation: 11
#4
RE: Player Footsteps

(11-17-2013, 12:46 PM)The Mug Wrote: In the materials.cfg you can set the "StepType" for a material, but there does not seem to be any direct pointing to a file.
a step type could fx be "rock".
I will either assume that the step-types are coded into the core, or that the game is coded to look for that the sound files in the steps folder are named correctly.
fx theres "step_walk_rock.snt", which means that the game might be able to detect on it's own that "this is a step_walk footstep" and that "the type is rock", so if someone writes "rock" as step-type for a material the game might be able to detect it simply because of the naming. I have not tested this myself though so it might just be coded into the source code, in which case you will have to rely on replacing existing step-types with FC.

This guy's basically got it. I've done this for my FC mod. I'm going to try and explain how to do it and I'm assuming you have a basic understanding of the materials.cfg file and the material editor! If you open materials.cfg, there will be a list of materials. For each material, there is a StepType field. Say the StepType is called "concrete", then for that material's footstep sounds, the engine will look for step_walk_concrete.snt and step_run_concrete.snt. I'm assuming you know how to add multiple .ogg files to a single .snt file, this is what you need to do for these sounds so they have multiple footstep sounds.

Lastly and most importantly, you need to create a new materials.cfg file as you can't really modify the original one. Just copy and paste the materials.cfg file into your mod's folder somewhere and modify the main_init.cfg file to point to the new materials.cfg. Add new materials to the new materials.cfg file (it's literally just a matter of changing the sound files it points to and changing the name, StepType and a few fields). ImpactSounds are the sounds played when you throw something at that material. Lastly, you won't be able to apply the MaterialType in the material editor because the material editor uses the default materials.cfg file (and there is no way to change this as far as I can tell), so what I did was to create the material (.mat file), then open it up in notepad++ (or use a similar program) and change the material type in there manually. Not great at explaining stuff but hope this helps!

Closure ModDB page:

[Image: 16LO8Sx]
(This post was last modified: 11-17-2013, 02:16 PM by ExpectedIdentifier.)
11-17-2013, 02:11 PM
Find
RaideX Offline
Member

Posts: 212
Threads: 33
Joined: May 2013
Reputation: 7
#5
RE: Player Footsteps

(11-17-2013, 02:11 PM)sonataarctica Wrote:
(11-17-2013, 12:46 PM)The Mug Wrote: In the materials.cfg you can set the "StepType" for a material, but there does not seem to be any direct pointing to a file.
a step type could fx be "rock".
I will either assume that the step-types are coded into the core, or that the game is coded to look for that the sound files in the steps folder are named correctly.
fx theres "step_walk_rock.snt", which means that the game might be able to detect on it's own that "this is a step_walk footstep" and that "the type is rock", so if someone writes "rock" as step-type for a material the game might be able to detect it simply because of the naming. I have not tested this myself though so it might just be coded into the source code, in which case you will have to rely on replacing existing step-types with FC.

This guy's basically got it. I've done this for my FC mod. I'm going to try and explain how to do it and I'm assuming you have a basic understanding of the materials.cfg file and the material editor! If you open materials.cfg, there will be a list of materials. For each material, there is a StepType field. Say the StepType is called "concrete", then for that material's footstep sounds, the engine will look for step_walk_concrete.snt and step_run_concrete.snt. I'm assuming you know how to add multiple .ogg files to a single .snt file, this is what you need to do for these sounds so they have multiple footstep sounds.

Lastly and most importantly, you need to create a new materials.cfg file as you can't really modify the original one. Just copy and paste the materials.cfg file into your mod's folder somewhere and modify the main_init.cfg file to point to the new materials.cfg. Add new materials to the new materials.cfg file (it's literally just a matter of changing the sound files it points to and changing the name, StepType and a few fields). ImpactSounds are the sounds played when you throw something at that material. Lastly, you won't be able to apply the MaterialType in the material editor because the material editor uses the default materials.cfg file (and there is no way to change this as far as I can tell), so what I did was to create the material (.mat file), then open it up in notepad++ (or use a similar program) and change the material type in there manually. Not great at explaining stuff but hope this helps!

Awesome explanation. I think i've got it working, thanks for that :3

If you don't draw first, you don't get to draw at all... -The False Shepherd
11-17-2013, 03:00 PM
Find
ExpectedIdentifier Offline
Member

Posts: 234
Threads: 10
Joined: Sep 2012
Reputation: 11
#6
RE: Player Footsteps

(11-17-2013, 03:00 PM)RaideX Wrote: Awesome explanation. I think i've got it working, thanks for that :3

No problem! Just thought I'd add, MaterialType is the material's name (the first field for that material in materials.cfg, not the StepType Smile

Closure ModDB page:

[Image: 16LO8Sx]
11-17-2013, 03:05 PM
Find




Users browsing this thread: 1 Guest(s)