{{newin|[[0.8.0]]|080|type=function}}
{{oldin|[[0.9.0]]|090|type=function|text=It has been renamed to [[Source:setAttenuationDistances]]}}
Sets the reference and maximum distance of the source.

== Function ==
=== Synopsis ===
<source lang="lua">
Source:setDistance( ref, max )
</source>
=== Arguments ===
{{param|number|ref|The new reference distance.}}
{{param|number|max|The new maximum distance.}}
=== Returns ===
Nothing.
== See Also ==
* [[parent::Source]]
[[Category:Functions]]
{{#set:Description=Sets the reference and maximum distance of the source.}}
{{#set:Since=080}}
== Other Languages ==
{{i18n|Source:setDistance}}