Skip to content

ColorSeries

Color series is a data type that represents a collection of color and points, also known as gradient.

Not newable

This object cannot be created by scripts using Instance.New().

Properties

PointCount : number

Returns the point count of this color series

Methods

New → ColorSeries

Parameters: ``

Create color series by this color range

New → ColorSeries

Parameters

min [ Color ]

max [ Color ]

Create color series by this color range

Clear → nil

Parameters: ``

Clear this ColorSeries

SetColor → nil

Parameters

point [ number ]

color [ Color ]

Sets the color at the specified point in the color series.

RemovePoint → nil

Parameters: point [ number ]

Removes the point at the specified index from the color series.

GetOffsets → { number }

Parameters: ``

Get all offsets

GetColors → { Color }

Parameters: ``

Get all colors

SetOffset → nil

Parameters

point [ number ]

offset [ number ]

Sets the offset at the specified point in the color series.

GetColor → Color

Parameters: point [ number ]

Gets the color at the specified point in the color series.

GetOffset → number

Parameters: point [ number ]

Gets the offset at the specified point in the color series.

AddPoint → number

Parameters

offset [ number ]

color [ Color ]

Add color point to the series with offset

Lerp → Color

Parameters: t [ number ]

Interpolates between colors in the series based on the parameter t.