Skip to content

List<OutputValue, InputValue, ListDataType>

Abstract base class for lists used in particle behaviors.

Extended by

Type Parameters

OutputValue

OutputValue

Type of value produced by the list.

InputValue

InputValue = OutputValue

Type of value used to initialize the list.

ListDataType

ListDataType = OutputValue

Type of data contained within the list nodes.

Constructors

Constructor

ts
new List<OutputValue, InputValue, ListDataType>(): List<OutputValue, InputValue, ListDataType>;

Returns

List<OutputValue, InputValue, ListDataType>

Properties

_easeFunction

ts
protected _easeFunction: EaseFunction | null = null;

_first

ts
protected _first: ListNode<ListDataType> | null = null;

_isStepped

ts
protected _isStepped: boolean = false;

_list

ts
protected _list: ListStep<InputValue>[] = [];

interpolate()

ts
interpolate: (time) => OutputValue;

Function to interpolate values from the list.

Parameters

time

number

Returns

OutputValue

Interpolated value.

Throws

If the interpolate method has not been set.

Accessors

first

Get Signature

ts
get first(): ListNode<ListDataType>;

First node in the list.

Throws

If the list has not been initialized.

Returns

ListNode<ListDataType>


isInitialized

Get Signature

ts
get isInitialized(): boolean;

Indicates whether the list has been initialized.

Returns

boolean


isStepped

Get Signature

ts
get isStepped(): boolean;

Indicates whether the list uses stepped interpolation.

Returns

boolean

Set Signature

ts
set isStepped(value): void;
Parameters
value

boolean

Returns

void


list

Get Signature

ts
get list(): ListStep<InputValue>[];

Gets the list steps.

Returns

ListStep<InputValue>[]

Methods

initialize()

ts
initialize(data): void;

Initializes the list from data.

Parameters

data

ListData<InputValue>

Data to initialize the list with.

Returns

void


initializeList()

ts
abstract protected initializeList(data): void;

Initializes the list from data.

Parameters

data

ListData<InputValue>

Data to initialize the list with.

Returns

void


reset()

ts
reset(): void;

Resets the list to an uninitialized state.

Returns

void