Difference between revisions of "Self-Destruction"

From Second Life Wiki
Jump to navigation Jump to search
m (lsl code tagging)
(format)
Line 12: Line 12:
     {
     {
         //upon creation, immediately start the timer
         //upon creation, immediately start the timer
         ''llSetTimerEvent(30.0)'';
         llSetTimerEvent(30.0); // Change this to set time in seconds
     }
     }



Revision as of 15:29, 30 March 2008

Change the number in llSetTimerEvent(30.0) to set the time, in seconds, that it will take for the object to disappear.

Script

<lsl> // Davada Gallant (John Girard), WWIIOLers // 30-second self destructor

default {

   state_entry()
   {
       //upon creation, immediately start the timer
       llSetTimerEvent(30.0); // Change this to set time in seconds
   }
   //once the timer ticks off, kill the object
   timer()
   {
       llDie();   
   }

}</lsl>