Surface Sounds: Difference between revisions

From Bohemia Interactive Community
Jump to navigation Jump to search
No edit summary
m (Text replacement - " ( *class [a-zA-Z0-9_]+): *([a-zA-Z0-9_]+ *) " to " $1 : $2 ")
 
(10 intermediate revisions by 3 users not shown)
Line 1: Line 1:
(For more detail on default classes of sounds available, use a config explorer or the '''ALLINONE config''' available from Dev-Heaven.)
==Surface sound definitions for 3D models==
=== Source of other references ===
For more detail on default classes of sounds available, use a config explorer or the '''ALLINONE config''' available from Dev-Heaven.


=== Where Used ===
The faces used in the ROADWAY LODs in 3d models provides at least 2 functions.
The faces used in the ROADWAY LODs in 3d models provides at least 2 functions.
(This is very similar to how surface sounds are defined for Terrains also)
(This is very similar to how surface sounds are defined for Terrains also)
First, defining what the game engine considers a floor or roadway, so things dont fall through
First, defining what the game engine considers a floor or roadway, so things dont fall through
Second, defines the sound that surface generates when it for example is walked on.
Second, defines the sound that surface generates when it for example is walked on.


=== The Surfaces ===
The later is defined in '''CfgSurfaces''' and then directly ascociated with a "Man" character via class '''SoundEnvironExt''' in class '''CAManBase'''.
The later is defined in '''CfgSurfaces''' and then directly ascociated with a "Man" character via class '''SoundEnvironExt''' in class '''CAManBase'''.


Modder and Terrain makers can either use the default definitions or add classes.
Modder and Terrain makers can either use the default definitions or add classes.
As the default definitions are over 1000 lines, heres are samples instead;
As the default definitions are over 1000 lines, heres are samples instead;
<code>
<code style="display: block">class CfgSurfaces
class CfgSurfaces
{
{
...
...
Line 28: Line 35:
impact = "default_Mat";
impact = "default_Mat";
};
};
class Roadway: Default
class Roadway : Default
{
{
access = 2;
access = 2;
Line 37: Line 44:
character = "Empty";
character = "Empty";
};
};
class Parkety: Default
class Parkety : Default
{
{
access = 2;
access = 2;
Line 46: Line 53:
character = "Empty";
character = "Empty";
};
};
class Lepenka: Default
class Lepenka : Default
{
{
access = 2;
access = 2;
Line 57: Line 64:
...
...
...
...
class Asfalt: Roadway
class Asfalt : Roadway
{
{
access = 2;
access = 2;
Line 66: Line 73:
character = "Empty";
character = "Empty";
};
};
class Cesta: Roadway
class Cesta : Roadway
{
{
access = 2;
access = 2;
Line 75: Line 82:
character = "Empty";
character = "Empty";
};
};
class Sterk: Default
class Sterk : Default
{
{
access = 2;
access = 2;
Line 86: Line 93:
...
...
...
...
class Metal: Default
class Metal : Default
{
{
access = 2;
access = 2;
Line 96: Line 103:
impact = "Impact_Metal";
impact = "Impact_Metal";
};
};
class Plech: Default
class Plech : Default
{
{
access = 2;
access = 2;
Line 106: Line 113:
impact = "Impact_Metal";
impact = "Impact_Metal";
};
};
class Iron: Default
class Iron : Default
{
{
access = 2;
access = 2;
Line 116: Line 123:
impact = "Impact_Metal";
impact = "Impact_Metal";
};
};
class Wave_plate: Default
class Wave_plate : Default
{
{
access = 2;
access = 2;
Line 126: Line 133:
impact = "Impact_Metal";
impact = "Impact_Metal";
};
};
class Beton: Default
class Beton : Default
{
{
access = 2;
access = 2;
Line 135: Line 142:
character = "Empty";
character = "Empty";
};
};
class Carpet: Default
class Carpet : Default
{
{
access = 2;
access = 2;
Line 148: Line 155:
</code>
</code>


=== The Surface Parameters ===
The important parameters are the


The important parameters are the
<code style="display: block">files =
<code>files =
soundEnviron =
soundEnviron =
</code>
</code>
This is the file name of the texture that the sound will be associated with.
This is the file name of the texture that the sound will be associated with.
A hint of what the sound is is usually possible from the '''soundEnviron''' parameter.
A hint of what the sound is is usually possible from the '''soundEnviron''' parameter.


=== The Surface / Face Texture ===
'''When that texture is applied to ROADWAY LOD faces within a 3D model, walking on the surface will create the associated sound.'''
'''When that texture is applied to ROADWAY LOD faces within a 3D model, walking on the surface will create the associated sound.'''


EG
EG
<code>files = "plechprolis*";</code>
<code style="display: block">files = "plechprolis*";</code>
(soundEnviron = "steel"; ).
 
(soundEnviron = "steel"; )
 
Is trigger via the default texture;.
Is trigger via the default texture;.
'''ca\buildings\data\plechprolis.pac'''
'''ca\buildings\data\plechprolis.pac'''


Note the use of the * (star). This works as it looks, as a wild-card for file names.
Note the use of the * (star). This works as it looks, as a wild-card for file names.


=== The Sound File Definitions ===
The actual sound file(s) played (for Man class) come from the '''SoundEnvironExt''' definitions.
The actual sound file(s) played (for Man class) come from the '''SoundEnvironExt''' definitions.
i.e. for "steel" as above;
i.e. for "steel" as above;
<code>steel[] = {{"\CA\sounds\Characters\steel\run_1",0.0316228,1,37},{"\CA\sounds\Characters\steel\run_2",0.0316228,1,37}, ........</code>
 
<code style="display: block">steel[] = {{"\CA\sounds\Characters\steel\run_1",0.0316228,1,37},{"\CA\sounds\Characters\steel\run_2",0.0316228,1,37}, ........</code>


Default classes for sound files.
Default classes for sound files.
<code>
<code style="display: block"> class SoundEnvironExt
class SoundEnvironExt
{
{
normalExt[] =
normalExt[] =
Line 201: Line 216:
</code>
</code>


'''Related Threads'''
=== Related BIF Threads ===
http://forums.bistudio.com/showthread.php?127296-different-sounds-inside-a-building
 
{{Link|link= http://forums.bistudio.com/showthread.php?127296-different-sounds-inside-a-building|text= different-sounds-inside-a-building}}
 
{{Link|link= http://forums.bistudio.com/showthread.php?85582-Adding-footstep-sounds|text= Adding-footstep-sounds}}


http://forums.bistudio.com/showthread.php?85582-Adding-footstep-sounds
{{Link|link= http://forums.bistudio.com/showthread.php?69228-Custom-sounds|text= Custom-sounds}}


http://forums.bistudio.com/showthread.php?69228-Custom-sounds
{{Link|link= http://forums.bistudio.com/showthread.php?68338-Roads-and-their-proper-sounds|text= Roads-and-their-proper-sounds}}


http://forums.bistudio.com/showthread.php?68338-Roads-and-their-proper-sounds
{{Link|link= http://forums.bistudio.com/showthread.php?67191-List-of-soundEnviron|text= List-of-soundEnviron}}


http://forums.bistudio.com/showthread.php?67191-List-of-soundEnviron
{{Link|link= http://forums.bistudio.com/showthread.php?65081-Sound-(-forest-and-snow-)|text= Sound-(-forest-and-snow-)}}


http://forums.bistudio.com/showthread.php?65081-Sound-(-forest-and-snow-)


=== Vehicle Sounds Side Note ===
Surface sounds for vehicles are defined within each vehicle class via sound classes like '''TiresAsphaltOut, TiresAsphaltIn, TiresGravelOut, TiresGravelIn, TiresMudOut''' etc etc


'''Side note'''
{{GameCategory|arma1|Terrain Editing}}
Surface sounds for vehicles are defined within each vehicle class via sound classes like [B]TiresAsphaltOut, TiresAsphaltIn, TiresGravelOut, TiresGravelIn, TiresMudOut[/B] etc etc

Latest revision as of 11:58, 6 December 2023

Surface sound definitions for 3D models

Source of other references

For more detail on default classes of sounds available, use a config explorer or the ALLINONE config available from Dev-Heaven.

Where Used

The faces used in the ROADWAY LODs in 3d models provides at least 2 functions.

(This is very similar to how surface sounds are defined for Terrains also)

First, defining what the game engine considers a floor or roadway, so things dont fall through

Second, defines the sound that surface generates when it for example is walked on.

The Surfaces

The later is defined in CfgSurfaces and then directly ascociated with a "Man" character via class SoundEnvironExt in class CAManBase.

Modder and Terrain makers can either use the default definitions or add classes.

As the default definitions are over 1000 lines, heres are samples instead; class CfgSurfaces { ... ... class Water { access = 2; files = "more_anim*"; rough = 0; dust = 0; soundEnviron = "water"; friction = 0.9; restitution = 0; isWater = 1; character = "Empty"; impact = "default_Mat"; }; class Roadway : Default { access = 2; files = "silnice*"; rough = 0.005; dust = 0.01; soundEnviron = "road"; character = "Empty"; }; class Parkety : Default { access = 2; files = "parkety*"; rough = 0.005; dust = 0.001; soundEnviron = "parkety"; character = "Empty"; }; class Lepenka : Default { access = 2; files = "lepenka*"; rough = 0.001; dust = 0.001; soundEnviron = "lepenka"; character = "Empty"; }; ... ... class Asfalt : Roadway { access = 2; files = "asfalt*"; rough = 0.01; dust = 0.05; soundEnviron = "road"; character = "Empty"; }; class Cesta : Roadway { access = 2; files = "cesta*"; rough = 0.08; dust = 0.15; soundEnviron = "dirt"; character = "Empty"; }; class Sterk : Default { access = 2; files = "sterk*"; rough = 0.08; dust = 0.15; soundEnviron = "gravel"; character = "Empty"; }; ... ... class Metal : Default { access = 2; files = "plechprolis*"; rough = 0.1; dust = 0.1; soundEnviron = "steel"; character = "Empty"; impact = "Impact_Metal"; }; class Plech : Default { access = 2; files = "plech*"; rough = 0.1; dust = 0.1; soundEnviron = "steel"; character = "Empty"; impact = "Impact_Metal"; }; class Iron : Default { access = 2; files = "ocel*"; rough = 0.1; dust = 0.1; soundEnviron = "metal"; character = "Empty"; impact = "Impact_Metal"; }; class Wave_plate : Default { access = 2; files = "vlnityplech*"; rough = 0.1; dust = 0.1; soundEnviron = "wave_plate"; character = "Empty"; impact = "Impact_Metal"; }; class Beton : Default { access = 2; files = "kameny"; rough = 0.1; dust = 0.1; soundEnviron = "concrete_ext"; character = "Empty"; }; class Carpet : Default { access = 2; files = "dum_mesto_koberec*"; rough = 0.1; dust = 0.1; soundEnviron = "carpet"; character = "Empty"; }; ... ...

The Surface Parameters

The important parameters are the

files = soundEnviron = This is the file name of the texture that the sound will be associated with.

A hint of what the sound is is usually possible from the soundEnviron parameter.

The Surface / Face Texture

When that texture is applied to ROADWAY LOD faces within a 3D model, walking on the surface will create the associated sound.

EG files = "plechprolis*";

(soundEnviron = "steel"; )

Is trigger via the default texture;.

ca\buildings\data\plechprolis.pac

Note the use of the * (star). This works as it looks, as a wild-card for file names.

The Sound File Definitions

The actual sound file(s) played (for Man class) come from the SoundEnvironExt definitions.

i.e. for "steel" as above;

steel[] = {{"\CA\sounds\Characters\steel\run_1",0.0316228,1,37},{"\CA\sounds\Characters\steel\run_2",0.0316228,1,37}, ........

Default classes for sound files. class SoundEnvironExt { normalExt[] = normal[] = road[] = rock[] = water[] = gravel[] = gravel2[] = sand[] = drygrass[] = grass[] = forest[] = mud[] = wood[] = wood_int[] = carpet[] = concrete_int[] = concrete_ext[] = metal[] = steel[] = hallway[] = dirt[] = parkety[] = wave_plate[] = lepenka[] = };

Related BIF Threads

different-sounds-inside-a-building

Adding-footstep-sounds

Custom-sounds

Roads-and-their-proper-sounds

List-of-soundEnviron

Sound-(-forest-and-snow-)


Vehicle Sounds Side Note

Surface sounds for vehicles are defined within each vehicle class via sound classes like TiresAsphaltOut, TiresAsphaltIn, TiresGravelOut, TiresGravelIn, TiresMudOut etc etc