Custom particles

A particle system is a rendering technique used to display complex and often fluid effects. Many games use particle systems for effects such as fire, water, spells, etc. There are several ROBLOX instances that use particles to create their effects, such as Fire and Sparkles. While the default particle systems that ROBLOX provides can be used in a variety of games and settings, there is a limit to how much they can be customized. More customizable systems can be created with the ParticleEmitter Instance.

Texture[edit]

Particle systems are made up of sprite textures, often overlaid and blended. In ROBLOX, a particle is always billboarded so it will always face the screen. A ParticleEmitter can use any custom texture you like by changing the Texture field, just as you would for a Decal or ImageLabel.

Texture.gif

Parent[edit]

The Part a ParticleEmitter is parented to determines the direction and origin of the particles created in the system. For a ParticleEmitter system to work, its parent must be a subtype of BasePart, such as a Part. The starting position of each particle created by the emitter is a randomly chosen point from within the volume of the ParticleEmitter's Parent.

EmitVolume.png

If the ParticleEmitter has a non-zero Speed property then the created particles will travel along the part's local Y axis. Rotating the Parent will change the direction new particles travel.

EmitDirection.gif

Lifetime[edit]

Particles exist for a limited time which is determined by the ParticleEmitter's Lifetime property. Lifetime defines a minimum and maximium amount of time in seconds a particle will last. When a new particle is created it's lifetime will be randomly chosen between the Lifetime minimum and maximum values. Setting minimum and maximum to the same value will ensure the particles will last for an exact amount of time. The maximum value of Lifetime is capped at 20 seconds.

Rate[edit]

Rate determines how many particles per second a ParticleEmitter will create. An individual emitter can emit up to 500 particles per second.

Note: There is a cap to how many particles can be rendered at a time. Each client can only render 16000 particles at once. New particles can be created if the number of particles exceed this cap, but they will not be rendered.

Rotation[edit]

The Rotation property determines how much each particle is rotated when it is created. Rotation defines a minimum and maximum rotation value in degrees. When a new particle is created a value is picked at random between the minimum and maximum. The particle is then rotated by this value. Note that minimum can be negative (for counter-clockwise rotation).

RotSpeed[edit]

RotSpeed determines how fast particles rotate while they are active. This property defines a minimum and maximum value in degrees per second. When a new particle is created a value is picked at random between the minimum and maximum. The particle will then constantly rotate at this value. Note that minimum can be negative (for counter-clockwise rotation).

VelocitySpread[edit]

By default particles will travel along the local Y axis of its Parent. VelocitySpread defines an offset range that particles can travel in. This offset is measured in degrees from the Y axis. This can be effectively set between 0 and 180 degrees.

0 degrees VelocitySpread
30 degrees VelocitySpread

Acceleration[edit]

Particles are not affected by regular gravity or ROBLOX forces. Acceleration defines an acceleration in studs per second (per second). This acceleration affects all particles created by the ParticleEmitter. Changing this value will instantly apply the acceleration to all particles made by the emitter (both existing and new particles).

Color[edit]

Particles can have color through the Texture, but a tint can also be applied with the Color property. Color defines two colors, a Start and an End. The color of each particle will be linearly interpolated between these two colors over its lifetime. If you don't need the colors to transition you can set the Start and End colors to the same value.

LightEmission[edit]

Particles can be blended together using additive blending. In additive blending, when two colors overlap their color values are added together to determine the displayed color. This often brings the color closer to white, which creates a glowing type effect. The value of LightEmission determines how much the particles in the emitter's system will additively blend (0 means no blending, 1 meaning fully additive).

Note: This property does not interact with ROBLOX's dynamic lighting system. Particles do not illuminate their surroundings. If you need that behavior, it is recommended using a light such as a PointLight or SurfaceLight in an invisible part.

Size[edit]

Particles can vary in size even throughout their lifetime. The simplest way to do this is to set the Size property to a number between 0 and 10. This will force all particles created by the ParticleEmitter to be that size. Size is measured in studs.

Alternatively this value can be set via a NumberSequence. The easiest way to do this is through the Studio spline editor. Next to the Size field in the emitter's properties is a button to open the editor. This editor represents a particle's size over it's lifetime (the x axis is time, the y axis is size). Clicking anywhere on the line will create a new node. Each node, including the starting and ending nodes can be dragged. In addition, the handles above and below each node can be dragged. This creates a red envelope on the graph. This envelope represents a random range of sizes a particle can be at that point.

Particles can be up to 10 studs large.

Transparency[edit]

Particles can vary in transparency throughout their lifetime. The Transparency property is set in the same way as Size, with the only exception being that Transparency values can only be between 0 and 1.

ZOffset[edit]

A part can contain multiple particle emitters. When this happens, particles will sometimes fight to determine which is drawn on top. In cases where you want to ensure some particles draw on top of others use the ZOffset property. This shifts the particles in the Z axis of the camera (either closer or further). This value is measured in studs. This is useful when you need certain particles to always draw on top, no matter which orientation you view them from.