LlPreloadSound

De DigiWiki.

//Will preload a sound when rezzed, then play it when 'touched'.
 
string sound = "name or uuid";//sound in inventory or UUID of a sound.
 
default
{
    on_rez(integer start_param)
    {
        llSetText("Preloading....",<1,0,0>,1);
        llPreloadSound(sound);
        llSetText("Touch To Play",<1,1,1>,1);
    }
    touch_start(integer num_detected)
    {
        llPlaySound(sound, 1.0);
    }
}
Outils personnels
  • Cette page a été consultée 634 fois.
donate
Google Ads