Welcome to the Second Life Forums Archive

These forums are CLOSED. Please visit the new forums HERE

problem with particles and targets inside a linked set

philippe Etzel
Registered User
Join date: 11 May 2008
Posts: 6
07-29-2008 09:58
Hi. I am using 3 particle emitters in an object, with the target option enabled (the three targets being linked prims in the same object).

I am using the particle laboratory templates. I just modified one part of the script as follows (1 example/3) :

"
// After-Effect & Influence Parameters:
PSYS_SRC_ACCEL, < 00.00, 00.00, 00.0>,
PSYS_SRC_TARGET_KEY, (key) llGetLinkKey(20),

PSYS_PART_FLAGS, (integer) ( 0 // Texture Options:
| PSYS_PART_INTERP_COLOR_MASK
| PSYS_PART_INTERP_SCALE_MASK
| PSYS_PART_EMISSIVE_MASK
| PSYS_PART_FOLLOW_VELOCITY_MASK
// After-effect & Influence Options:
// | PSYS_PART_WIND_MASK
// | PSYS_PART_BOUNCE_MASK
// | PSYS_PART_FOLLOW_SRC_MASK
| PSYS_PART_TARGET_POS_MASK
| PSYS_PART_TARGET_LINEAR_MASK
)
//end of particle settings
"

Everything works fine, except that, when I rezz the object again, the particles don't "work" (show) spontaneously..... They do only if I manuallly reset them in each individual prim....?

I added a touch toggle (which I didn't really needed..) but it doesn't change anything....?

Thanks for your help..

PS : The particle laboratory is fantastic ! I wanted to give a contribution but couldn't find any tipjar there... If you know where it is, please let me know....;)
Hewee Zetkin
Registered User
Join date: 20 Jul 2006
Posts: 2,702
07-29-2008 11:27
The key of every prim is going to be different each time the object is rezzed. So put the llParticleSystem() call in a function and call it not only from your default/state_entry handler (or wherever) but also afresh each time you get an 'on_rez' event (alternately you could just call llResetScript() from the 'on_rez' handler). That way 'llGetLinkKey(20)' will get the NEW key of the 20th prim in your link set after the rez, and the particles won't all seek out the prims in the original object if you rez new ones. ;)
philippe Etzel
Registered User
Join date: 11 May 2008
Posts: 6
07-29-2008 13:12
Hmm... I didn't really understand the first method...? ( lol, sorry...I'm a beginner...), so I used the second method you suggested, and it works fine !
Thanks ! :)