Does it make sense, and really use less system resources, if those flames are generated as temp-on-rez? If I have 8 torches around my deck, and each is using 4 prims to make the animated flames, I would save 32 prims on my parcel prim count. But would the necessary temp-on-rez scripting cause too much lag to be worth it?
In particular, I have a Tiki Torch that I designed, and that I have been selling. Right now, the whole thing is phantom, because the planes of the animated flames stick out too far for them to be done otherwise. It uses fullbright on two flame planes and local lighting on two others, so it looks nice whether local lighting is enabled or not. But it's always 'lit', and there is no way to extinguish the torch.
I would like to script a new version of the torch to do the following.
* Anyone can touch the torch to get a menu.
* Menu alows anyone to extinguish the torch if it is lit, or to light it by rezzing an appropriate 4-prim, phantom, temp-on-rez flame object just above the position of the torch.
* Menu allows Owner to set a non-zero chat channel to link multiple torches, so any one torch in the sim on the same channel can control the others that this owner has in place. If this feature is turned off, it has no open listens.
Optional goodness, if possible.
* Auto-extinguish: Menu choice toggles auto-extinguish on or off. If this feature is on, while a flame object is being ressed, the source object scans area once per 10 minutes to see if any avatars are present. If no one is around for two consecutive scans, turn off the flames (stop using resources for temp on rez), and stop scanning. If auto-extinguish is off, the torch continues to generate flames until extinguished with the menu command.
=============
In the script library, I found the "Temp Prim Rezzer, by Eata Kitty, which seems to do a fair amount of what I would want. But it also has a lot of code that looks to me like it would be unnecessary, if scripting the object for a specific purpose, like my Tiki torch.
I would like to make the script something that could also be adapted for making candles, oil lamps, fireplaces, and other things that use flames and which don't always need to be lit.
Plan B :

If all that is just too laggy or too much hassle to code, I suppose I could just script the current torch to toggle the visibility of the flame prims. But of I do that, will the 'hidden' flames still be a local lighting source? Or to put it another way, would it keep glowing if the flames are 100% alpha, and I don't also toggle the local lighting property of the flame prims?