Garry's Mod Wiki

IGModAudioChannel:Set3DFadeDistance

  IGModAudioChannel:Set3DFadeDistance( number min, number max )

Description

Sets 3D fade distances of a sound channel.

Arguments

1 number min
The minimum distance. The channel's volume is at maximum when the listener is within this distance.

0 or less = leave current.

2 number max
The maximum distance. The channel's volume stops decreasing when the listener is beyond this distance.

0 or less = leave current.

Example

The default values.

Channel:Set3DFadeDistance( 200, 1000000000 )