Custom Linden Plants

Background

Currently, all plants are defined in trees.xml, which looks like this

<tree name="Pine 1" species_id="0" texture_id="0187babf-6c0d-5891-ebed-4ecab1426683"
      droop="60.0" twist="5.0" branches="5.0" depth="1" scale_step="0.7" trunk_depth="6"
      branch_length="8.0" trunk_length="11.5" leaf_scale="22.0" billboard_scale="39.5"
      billboard_ratio="1.1" trunk_aspect="0.1" branch_aspect="0.05" leaf_rotate="20.0"
      noise_mag="0.5" noise_scale="2.5" taper="0.8" repeat_z="3" />

and grass.xml, which looks like this:

<grass
    name="Grass 0"
        species_id="0"
        texture_name="grass_texture_2.tga"
        blade_size_x="1.35"
        blade_size_y="1.35"
     />

Either of these are pretty small chunks of data, and could easily be attached to a prim and configured with an LSL call similar to LLParticleSystem. Any other shape attributes of the prim so equipped could be ignored (and as an optimization, could simply not be downloaded). The prim would display as the selected plant, phantom, non-physical, moved by wind, etcetera.

Implementation

<lsl>llPlantSystem(list plant)</lsl>

Set the "plant system" parameters for the prim.

Parameters:

Notes

Since these are prims they could be linked to a build, and would be able to replace unlinked Linden trees in sold builds simply by specifying (for example) llPlantSystem([PLANT_TYPE_TREE,SPECIES_PINE_1]) with no texture or other parameters.

Since they would be phantom and simple, they would have as little impact on the sim as a regular tree.

They would reduce the number of prims in use.

They would create new building opportunities, including things like:

Enhancements