The Developer Hub is now deprecated and information on this page may no longer be accurate. To see our new and improved documentation, please click here. You can read more about the future of documentation here.
Collapse Sidebar




The maximum distance, in studs, a client’s listener can be from the Sound|Sound's origin and still hear it. Only applies to Sounds parented to a Part or Attachment (3D sounds).

How MaxDistance impacts the attenuation of a sound (manner in which it fades out) is dependent on the Sound/RollOffMode property. When RollOffMode is set to use an inverse type distance model (Inverse or InverseTapered) the MaxDistance will not effect the attenuation of the sound. This means that low values for MaxDistance will cause the sound to abruptly cut off when the listener reaches the MaxDistance. In most cases this is not desirable and developers are advised not to use low MaxDistance values.

When RollOffMode is set to a linear type distance model (Linear or LinearSquared) the sound will attenuate between Sound/EmitterSize and MaxDistance (with playback volume reaching zero at MaxDistance). This is less realistic, but in some cases allows attenuation to be handled in a more intuitive way.

Code Samples

Sound MaxDistance

This sample includes a brief demonstration of how Sound.MaxDistance works.

A Part is instanced in the Workspace with a looped Sound playing within it. A function is made to listen to the Sound’s MaxDistance and change the size of a sphere whenever it changes. The sphere’s radius will always be equal to the Sound’s MaxDistance.

This example helps demonstrate how the sound is only audible when the client’s listener (by default the Camera’s position) is within the sphere.