Difference between revisions of "LlSetSoundRadius"

From Second Life Wiki
Jump to navigation Jump to search
m
(Added note about how to disable. Added 2 examples.)
Line 7: Line 7:
|return_text
|return_text
|spec
|spec
|caveats
|caveats=
* This function is a prim property, thus will survive script resets.
|constants
|constants
|examples
|examples=
Enable sound cutoff at 4 meters.
<source lang="lsl2">
llSetSoundRadius(4); //Enable sound cutoff at 4 meters.
</source>
Disable sound cutoff.
<source lang="lsl2">
llSetSoundRadius(0); //Disable sound cutoff.
</source>
|helpers
|helpers
|also_functions={{LSL DefineRow||[[llTriggerSoundLimited]]|}}
|also_functions={{LSL DefineRow||[[llTriggerSoundLimited]]|}}
Line 15: Line 24:
|also_events
|also_events
|also_articles
|also_articles
|notes
|notes=
Pass 0 to this function to disable it.
|cat1=Sound
|cat1=Sound
|cat2
|cat2

Revision as of 08:33, 23 April 2022

Summary

Function: llSetSoundRadius( float radius );
0.0 Forced Delay
10.0 Energy

Establishes a hard cut-off radius for audibility of scripted sounds (both attached and triggered).

• float radius in meters

Caveats

  • This function is a prim property, thus will survive script resets.

Examples

Enable sound cutoff at 4 meters.

llSetSoundRadius(4); //Enable sound cutoff at 4 meters.

Disable sound cutoff.

llSetSoundRadius(0); //Disable sound cutoff.

Notes

Pass 0 to this function to disable it.

See Also

Functions

•  llTriggerSoundLimited

Deep Notes

History

Footnotes

  1. ^ Early release notes were not very accurate or thorough, they sometimes included information about features added in previous releases or failed to include information about features added in that release.

Signature

function void llSetSoundRadius( float radius );