Unofficial LSL Reference

[[functions:llstopsound]]


Unofficial LSL reference

User Tools

Login

You are currently not logged in! Enter your authentication credentials below to log in. You need to have cookies enabled to log in.

Login

Forgotten your password? Get a new one: Set new password

Function: llStopSound

llStopSound()

Stops the sound playing in the prim the script is running in.

Notes

Short examples

llStopSound(); // stops a running sound

Complete examples

This script will start a looped sound when it is touched, and stop it when it is touched again.

llStopSound-example.lsl
integer sound;

default
{
    touch_start(integer n)
    {
        sound = !sound;
        if (sound)
            // Start the Jetpack looped sound at full volume.
            llLoopSound("67f5e4f0-0534-4d97-bc01-f297648d20e0", 1.0);
        else
            // Stop it
            llStopSound();
    }
}

See also