Revision Difference
Structures/SoundData#552723
<cat>struct</cat>⤶
<structure>
<realm>Shared</realm>
<description>Table used in <page>sound.Add</page> and <page>sound.GetProperties</page>.</description>
<fields>
<item name="sound" type="string">Path to the sound file to be used in this sound effect, relative to `sound/` directory (so exclude the `sound/` part).
Can be a table of sound files, in which case the sound will be chosen randomly every time from the provided list.
Each sound path can be prepended with a special character for special effects. You can learn more about this [here](https://developer.valvesoftware.com/wiki/Soundscripts#Sound_Characters).
</item>
<item name="name" type="string">The name of the soundscript, to be referenced by in functions such as <page>Entity:EmitSound</page>.</item>
<item name="channel" type="number">The sound channel to play in. See <page>Enums/CHAN</page></item>
<item name="level" type="number">The soundlevel of the sound in dB. See <page>Enums/SNDLVL</page>. This will affect how far the sound can be heard.</item>
<item name="volume" type="number" default="1.0">The volume of the sound as a decimal between `0` and `1`. Can be a table of two numbers, a minimum and a maximum value.
**Warning:** Volume of `0` will act as volume of `1`</item>
<item name="pitch" type="number" default="100">The pitch of the sound. Can be a table of two numbers, a minimum and a maximum value.</item>
<item name="pitchstart" type="number">The initial pitch.
<warning>Deprecated, use pitch.</warning>
</item>
<item name="pitchend" type="number">The pitch end.
<warning>Deprecated, use pitch.</warning>
</item>
</fields>
</structure>