Constructor

new(name:String, timeline:FlxTimeline)

Variables

curFrame:Int

The current frame.

read onlylayers:Array<String>

The amount of layers structured in names.

read onlylength:Int

The amount of frames the symbol has.

@:allow(flxanimate.animate.FlxSymbolDictionary)read onlylocation:String

name:String

The name of the symbol.

onCallback:() ‑> Void

The callback that's called for every fireCallbacks().

Methods

addCallbackTo(label:String, callback:Function, ?layer:EitherType<Int, String>):Bool

Adds a callback to a specific frame label.

Parameters:

label
callback
null

layer

@:value({ frame : null })getElement(index:Int, ?frame:Int):FlxElement

Gets an element through a specific index from a frame.

Parameters:

index

The element index.

frame

The keyframe the element is located. If set to null, it will take curFrame as a reference.

Returns:

an FlxElement instance.

@:value({ layer : null, frame : null })getElementByName(name:String, ?frame:Int, ?layer:EitherType<Int, String>):Null<FlxElement>

Gets a symbol element via the symbol's name or the instance's name inside a frame.

Parameters:

name

this can be either the name of the symbol or the instance.

frame

The keyframe the element is located. If set to null, it will take curFrame as a reference.

layer

Which layer it should take as a reference. if set to null, it'll take every layer available.

Returns:

an FlxElement instance.

@:value({ frame : null })getElementIndex(element:FlxElement, ?frame:Int):Int

Gets the element's position inside a frame.

Parameters:

element

The element in question.

frame

The keyframe the element is located. If set to null, it will take curFrame as a reference.

@:value({ layer : null })getFrameLabel(name:String, ?layer:EitherType<Int, String>):FlxKeyFrame

@:value({ layer : null })getFrameLabelNames(?layer:EitherType<Int, String>):Array<Null<String>>

@:value({ layer : null })getFrameLabels(?layer:EitherType<Int, String>):Array<FlxKeyFrame>

Gets a list of frames that have a label of any kind.

Parameters:

layer

A specific layer to get the list. if set to null, it'll get a list from every layer.

@:value({ layer : null })getNextToFrameLabel(label:String, ?layer:EitherType<Int, String>):Null<FlxKeyFrame>

hideLayer(layer:String):Void

Hides a layer from the timeline.

Parameters:

layer

The name of the layer.

@:value({ layer : null })removeAllCallbacksFrom(label:String, ?layer:EitherType<Int, String>):Bool

removeCallbackFrom(label:String, callback:EitherType<Function, Int>, ?layer:EitherType<Int, String>):Bool

Removes a callback from a certain label. can be extracted from a certain layer.

Parameters:

label

The label in question.

callback

The callback. Can be the actual function or an Int referring to its index.

layer

The layer in question.

showLayer(layer:String):Void

Shows a layer from the timeline.

Parameters:

layer

The name of the layer.

@:value({ frame : null })swapElements(oldElement:FlxElement, newElement:FlxElement, ?frame:Int):Void

Swaps an element with another one.

Parameters:

oldElement

The element you wanna replace

newElement

The new element that's gonna replace the old one

frame

The keyframe the element is located. If set to null, it will take curFrame as a reference.

@:value({ swfRender : false })inlineupdateRender(elapsed:Float, curFrame:Int, dictionary:Map<String, FlxSymbol>, swfRender:Bool = false):Void