Join us in Outworldz at www.outworldz.com:9000 or follow us:

Search dozens of selected web sites for OpenSim and LSL script

New! Script Meta-Search will search thousands of scripts here and at other sites for LSL or Opensim scripts.
Loading

Want to add a script or a project? Upload it and a half million people will see it and your name here this year.

Home   Show All
Category: Contributor: Creator
Particles Party_Fogger  

Party_Fogger

Party Fogger.lsl

Category: Particles
By : Anonymous
Created: 2010-01-10 Edited: 2010-01-10
Worlds: Second Life

the Zip file

Download all files for Party_Fogger
Contents are in zip format, with .LSL (text) source code and LSLEdit (text + Solution) formats.
Get file # 1. Party_Fogger_1.lsl
1
2
3 key SMOKE_SPRITE = "b85073b6-d83f-43a3-9a89-cf882b239488";
4
5 float SPRITE_SIZE = 3.0;
6 float LIFETIME = 10.0;
7 integer NUM_PARTICLES = 20;
8 // What initial velocity magnitude should particles have (in meters/s)?
9 float SPRITE_VELOCITY = 0.15;
10 // Width of cone (in Radians) about the object's Z axis where particle will be directed
11 float ARC = 0.5;
12 // Offset distance from the object center to generate the system
13 vector OFFSET = <0,0,-2.5>;
14
15 default
16 {
18 {
19
20 //llGiveInventory(llGetOwner(), "Party Fogger Instructions");
21 state stopped;
22 }
23
24
25 }
26 state smoking
27 {
29 {
30 llWhisper(0, "Fogger on");
31 llSetTimerEvent(2.0);
32 llTargetOmega(<0,0,1>, 2, 2);
33 }
34
35 touch_start (integer num_detected)
36 {
37 llSetTimerEvent(0.0);
38 state stopped;
39 }
40 timer()
41 {
42 if(llFrand(1.0) < 0.5)
43 {
44 //
45 // Make some smoke
46 //
47 llMakeSmoke( NUM_PARTICLES, 1.0, 0.2,
48 LIFETIME, 1.0, SMOKE_SPRITE, OFFSET);
49 }
50 }
51 }
52
53 state stopped
54 {
56 {
57 llTargetOmega(<0,0,1>, 0, 0);
58 llWhisper(0, "Fogger off");
59 }
60 touch_start (integer num_detected)
61 {
62 state smoking;
63 }
64 }
65 // END //

Back to the Best Free Tools in Second Life and OpenSim.