class flixel.tweens.misc.ColorTween extends FlxTween

Available on all platforms

Tweens a color's red, green, and blue properties * independently. Can also tween an alpha value.

Instance Fields

var blue:Int

Blue value of the current color, from 0 to 255.

var green:Int

Green value of the current color, from 0 to 255.

var red:Int

Red value of the current color, from 0 to 255.

var sprite:FlxSprite

Optional sprite object whose color to tween

function destroy():Void

Clean up references

function tween(Duration:Float, FromColor:Int, ToColor:Int, ?FromAlpha:Float = 1, ?ToAlpha:Float = 1, ?Sprite:FlxSprite = null):ColorTween

Tweens the color to a new color and an alpha to a new alpha. * *

Duration

Duration of the tween. *

FromColor

Start color. *

ToColor

End color. *

FromAlpha

Start alpha *

ToAlpha

End alpha. *

Sprite

Optional sprite object whose color to tween. *

returns

The ColorTween.