Particle

Information about a certain particle type that is shared between effects.

Summary
ParticleInformation about a certain particle type that is shared between effects.
Member Functions
SetColor
SetColoring1
SetColoring2
GetMotionController
SetBlendMode

Member Functions

SetColor

nil SetColor(Color color)

Sets the initial color of the particle.

Usage

particle:SetColor(Color(255,110,60,255));

SetColoring1

nil SetColoring1(Color color1, number startTimePercent)

Particle will fade to this color.

Parameters

color1A Color object holding the color we want to change to interpolate to.
startTimePercentAt what point the change should start to happen, 0 to 1.

SetColoring2

nil SetColoring2(Color color1, Color color2, number startTimePercent)

Like Particle::SetColoring1 except it allows you to fade to three colors total.

Parameters

color1A Color object holding the color we want to change to interpolate to.
color2The second Color object holding the color we want to change to interpolate to.
startTimePercentAt what point the change should start to happen, 0 to 1.

GetMotionController

MotionController GetMotionController()

Returns

The MotionController associated with this particle template.  (created if one doesn’t exist)

SetBlendMode

nil SetBlendMode(number blendConstant)

Only normal and additive modes are currently supported.

Parameters

blendConstantMust be one of the C_BLEND_MODE_CONSTANTS.
The color object stores R G B A color information.
All Particles have a motion controller that can be accessed for extra effects.