Flickers an object. See FlxTween.flicker()

Available since

5.7.0

.

Static methods

staticdefaultTweenFunction(tween:FlickerTween):Bool

The default tween function of flicker tweens

Parameters:

tween

The tween handling the flickering

Variables

read onlybasic:FlxBasic

The object being flickered

@:value(true)read onlyendVisibility:Bool = true

Whether the object will show after the tween, defaults to true

@:value(0.08)read onlyperiod:Float = 0.08

How often, in seconds, the visibility cycles

@:value(0.5)read onlyratio:Float = 0.5

The ratio of time the object will show, default is 0.5, meaning equal times visible and invisible.

read onlytweenFunction:FlickerTween ‑> Bool

Controls how the object flickers over time

Methods

destroy():Void

Clean up references

tween(basic:FlxBasic, duration:Float, period:Float):FlickerTween

Flickers the desired object

Parameters:

basic

The object to flicker

duration

Duration of the tween, in seconds

period

How often, in seconds, the visibility cycles

Inherited Variables

Defined by FlxTween

@:value(false)active:Bool = false

read onlybackward:Bool

@:value(0)duration:Float = 0

@:value(0)read onlyexecutions:Int = 0

How many times this tween has been executed / has finished so far - useful to stop the LOOPING and PINGPONG types after a certain amount of time

read onlyfinished:Bool

@:value(0)loopDelay:Float = 0

Seconds to wait between loops of this tween, 0 by default

manager:FlxTweenManager

The manager to which this tween belongs

Available since

4.2.0

.

percent:Float

Value between 0 and 1 that indicates how far along this tween is in its completion. A value of 0.33 means that the tween is 33% complete.

@:value(0)read onlyscale:Float = 0

@:value(0)startDelay:Float = 0

Seconds to wait until starting this tween, 0 by default

read onlytime:Float

The total time passed since start

Available since

5.7.0

.

Inherited Methods

Defined by FlxTween

cancel():Void

Immediately stops the Tween and removes it from its manager without calling the onComplete callback.

Yields control to the next chained Tween if one exists.

cancelChain():Void

Immediately stops the Tween and removes it from its manager without calling the onComplete callback or yielding control to the next chained Tween if one exists.

If control has already been passed on, forwards the cancellation request along the chain to the currently active Tween.

Available since

4.3.0

.

start():FlxTween

Starts the Tween, or restarts it if it's currently running.

then(tween:FlxTween):FlxTween

Specify a tween to be executed when this one has finished (useful for creating "tween chains").

wait(delay:Float):FlxTween

How many seconds to delay the execution of the next tween in a tween chain.