Welcome to the Second Life Forums Archive

These forums are CLOSED. Please visit the new forums HERE

Menu Driven Particle Changer

Zena Juran
Registered User
Join date: 21 Jul 2007
Posts: 473
09-12-2007 05:41
I have an object that I use a freebie animation poseball scipt. I modified the script to start particles emitting upon sit and stop emitting upon unsit.... simple enough. Now I would like to have the ability to change between 5 or 6 preset particles via a menu. As I look at various menu driven scripts, it seems this might not be so simple for my level of expertise atm. I would like to be able to generate the particle script portion outside of the main script and then copy and paste it in (as a variable). Any help on "lists" would be greatly appreciated. :-)
Debbie Trilling
Our Lady of Peenemünde
Join date: 17 Oct 2006
Posts: 434
09-12-2007 07:08
Lists are not necessary for this & it is simple enough once you understand llDialog.

http://rpgstats.com/wiki/index.php?title=LlDialog

Within the script, create a seperate function for each type of particle effect you wish to create. Populate the llParticleSystem() parameters within each of these functions for each effect and also make the call itself.

An IF statement (within the Listen) responds to the menu selection that the user makes, and calls the appropriate function that you have created for the particular particle effect selected.

http://rpgstats.com/wiki/index.php?title=Listen

As for creating outside of the main script & copy/pasting into the script. Again, this is simple enough. Create the particle effect within a simple prim and adjust the llParticleSystem() parameters until you get the desired result. Copy/paste the llParticleSystem() call from this simple prim, (and also any code you have written to populate it's parmeters) into one of the functions you have created ~ the functions also act as ready-made "placeholders", in the sense that you know exactly where to paste the amended code. :)

Remember to also copy any necessary variable declarations that you may have used to generate a value for the llParticleSystem() call parmeters.
Zena Juran
Registered User
Join date: 21 Jul 2007
Posts: 473
09-12-2007 10:31
Thanks Debbie

Your suggestion worked perfectly for me! :-)