Skip to content
lsl.devlsl.devLSL Dev

Effects

Effects are visual features rendered by the viewer from a few parameters set by a script. Once set, most of them keep running with no further script activity: the script describes the effect, it does not animate it frame by frame.

High quality effects often combine features: a technical mesh shape made in a modelling tool such as Blender, with an animated texture and glow, can look like particles while costing far less.

Concepts

Functions and events

voidllParticleSystem(list rules)
voidllLinkParticleSystem(integer link, list rules)
voidllSetText(string text, vector color, float alpha)
voidllSetTextureAnim(integer mode, integer face, integer sizex, integer sizey, float start, float length, float rate)
voidllSetLinkTextureAnim(integer link, integer mode, integer face, integer sizex, integer sizey, float start, float length, float rate)
voidllSetLinkPrimitiveParamsFast(integer link, list rules)

Particles

Particle rules are PSYS_* constants: emitter (PSYS_SRC_*) and particle (PSYS_PART_*) settings. See the reference below.

Technical mesh

A mesh shaped for the effect, with texture animation and glow, can replace many particles.

Scripting Details

voidllParticleSystem(list rules)
Creates or updates a particle system on the prim containing the script based on rules. An empty list removes the particle system.
voidllLinkParticleSystem(integer link, list rules)
Creates or updates a particle system on the linked prim link based on the list of rules. An empty list removes the particle system.
voidllSetText(string text, vector color, float alpha)
Displays floating text above the prim with the specified color vector and transparency alpha.
voidllSetTextureAnim(integer mode, integer face, integer sizex, integer sizey, float start, float length, float rate)
Animates the texture on face of the prim by setting its scale and offset. mode defines options, sizex/sizey define frames, start defines the start frame/angle, length defines duration, and rate defines playback speed.
voidllSetLinkTextureAnim(integer link, integer mode, integer face, integer sizex, integer sizey, float start, float length, float rate)
Animates the texture on face of the linked prim link by setting the scale and offset according to mode. Parameters sizex/sizey define frames, start defines the start frame/angle, length defines duration, and rate defines playback speed.
voidllSetLinkPrimitiveParamsFast(integer link, list rules)
Sets primitive parameters for the linked prim link according to rules with no built-in script sleep delay.

Additional

Constant groups ParticleParam 27ParticleFlag 10ParticleSourcePattern 5ParticleBlendFunc 8

Constant groups TextureAnimMode 7

See also Category ParticlesSL Wiki LSL ParticlesSL Wiki Script library: particlesPlanned Recipe: particle effect presets

See also SL Wiki LSL Floating Text

See also Feature Textures & MaterialsPlanned Guide: technical mesh with texture animation

See also SL Wiki LSL LightFeature Prims

See also Feature SoundCategory Effects