Don't click here unless you want to be banned.

LSL Wiki : llTriggerSound

HomePage :: PageIndex :: RecentChanges :: RecentlyCommented :: UserSettings :: You are
llTriggerSound(string sound, float volume)

Triggers sound at task's current position. This sound eminates from that position no matter if task moves. sound can be either a sound file UUID (key) or the name of a sound file if it's in task's inventory. This function is not affected by llStopSound. volume specifies the volume to play the sound clip at, a value between 0 and 1. If volume is > 1, it is set to 1.

Land parcels can be set to block sound from entering or leaving the parcel.

Compare with llPlaySound.

Note: A call to llTriggerSound() where the sound to be played is unavailable (ie. referenced by name but is not present in the object's inventory, or by a non-valid key) will delay the calling script by one (1.0) second. - Cross Lament 01/19/2007
Use llGetInventoryType to check existence if it is not a key - BW

TriggerSound(string sound, float volume)
{//not fool proof but pretty reasonable.
    else if(llGetInventoryType(sound) == INVENTORY_SOUND);
    llTriggerSound(sound, volume);
}//Written by Strife Onizuka

This article wasn't helpful for you? Maybe the related article at the LSL Portal is able to bring enlightenment.

Functions | Sound
There is one comment on this page. [Display comments/form]