setColorTransform() alternative for highlighting sprites



  • setColorTransform() works fine in Flash, but doesn't seem to work on cpp targets. I'm using HaxeFlixel 3.3.12 and OpenFL 3.5.3.

    I'm using setColorTransform() for gradually highlighting sprites, and it's not convenient for me to have a duplicate image file of each sprite highlighted since with the animation frames there are a lot of them.

    Is there any way I can do this on cpp targets? I want to be able to highlight sprites to almost full white, and then let the highlight gradually fade.


  • administrators

    See http://api.haxeflixel.com/flixel/FlxSprite.html?#setColorTransform:

    With FlxG.renderTile, offsets are only supported on OpenFL Next version 3.6.0 or higher.



  • I guess I need to update OpenFL then... thanks!


  • administrators

    Possibly also Flixel itself, I'm not sure 3.3.12 already supported it.


Log in to reply