Welcome to the Second Life Forums Archive

These forums are CLOSED. Please visit the new forums HERE

Confetti/snow Type Script..

Heathur Spaight
Registered User
Join date: 18 May 2005
Posts: 257
01-21-2009 17:49
I"m not a scripter so I am probably not even asking this the right way but..

Does anyone know how to makes particles fall from a sphere or any prim - to fall down to the ground like snow does. I have a confetti script but my particles are falling straight out and up. Not sure what to change inside the script. Thanks for any help and sorry if I didn't ask right!
Rolig Loon
Not as dumb as I look
Join date: 22 Mar 2007
Posts: 2,482
01-21-2009 18:40
See /54/d8/302790/1.html. Someone asked the same question last week. There must be something in the air. ;)
Heathur Spaight
Registered User
Join date: 18 May 2005
Posts: 257
01-21-2009 18:49
thank you, i'll check it out!
Heathur Spaight
Registered User
Join date: 18 May 2005
Posts: 257
01-21-2009 18:53
that says basically what the script i have says with the instructions at the top. i just can't figure out how to make the particles go all the way down but i'll keep trying.
Rolig Loon
Not as dumb as I look
Join date: 22 Mar 2007
Posts: 2,482
01-21-2009 21:48
Yes, but those particular parameters are snow particle parameters. Try them and see. The basic script always looks like that.
arton Rotaru
Registered User
Join date: 27 Aug 2007
Posts: 43
01-21-2009 22:15
Maybe this comes close to what you want.
You can play with PSYS_SRC_BURST_RADIUS,4.0, to make the output wider or narrower.

PSYS_SRC_ACCEL, <0.0,0.0,-0.5>, negative value on Z axis pushes the particles to ground.
CODE

integer switch = FALSE;

default
{
state_entry()
{
//code
}
touch_start(integer number){
//if (llDetectedKey(0) == llGetOwner()){
if (switch){
llSetTimerEvent(0.0);
llParticleSystem([ ]);
switch = FALSE;
}else{
llSetTimerEvent(0.1);
switch = TRUE;
}
}
timer(){
float color_1 = llFrand(1.0);
float color_2 = llFrand(1.0);
float color_3 = llFrand(1.0);

llParticleSystem([PSYS_PART_FLAGS,PSYS_PART_EMISSIVE_MASK
|PSYS_PART_INTERP_COLOR_MASK
|PSYS_PART_INTERP_SCALE_MASK
//|PSYS_PART_WIND_MASK
,
PSYS_PART_MAX_AGE,30.0,
PSYS_PART_START_COLOR, <color_1,color_2,color_3>,
PSYS_PART_END_COLOR, <color_1,color_2,color_3>,
PSYS_PART_START_SCALE,<.1,.1,.1>,
PSYS_PART_END_SCALE,<.1,.1,.1>,
PSYS_SRC_PATTERN, PSYS_SRC_PATTERN_EXPLODE,
PSYS_SRC_BURST_RATE,0.02,
PSYS_SRC_ACCEL, <0.0,0.0,-0.5>,
PSYS_SRC_BURST_PART_COUNT,5,
PSYS_SRC_BURST_RADIUS,4.0,
PSYS_SRC_BURST_SPEED_MIN,0.5,
PSYS_SRC_BURST_SPEED_MAX,1.5,
PSYS_SRC_INNERANGLE,1.0,
PSYS_SRC_OUTERANGLE,1.5,
PSYS_SRC_OMEGA, <1.0,1.0,1.0>,
PSYS_SRC_MAX_AGE, 0.0,
PSYS_SRC_TEXTURE, "",
PSYS_PART_START_ALPHA, 1.0,
PSYS_PART_END_ALPHA, 1.0
]);
}
}