Jump to content
Search Community

colorMatrixFilter reset [SOLVED]

isaballoon test
Moderator Tag

Recommended Posts

I have a question about nullifying colorization via manipulations of the colorMatrixFilter. I understand how to tween the value back to 0, but my I'm not sure how to get there without a tween... setting to a value of 0 straight away. Can someone show me how this is possible in the context of the following code? TIA

 

import com.greensock.*; 
import com.greensock.easing.*;

var one:String = "yes";
var slide:TweenMax;

stage.addEventListener(MouseEvent.CLICK, move);

function move(e:MouseEvent):void {
switch (one) {
	case "yes":
		TweenMax.to(clip, 1, {colorMatrixFilter:{colorize:0x33cc33, amount:0.7}});
		one = "no";
		break;
	case "no":
		// code to de-colorize clip without tweening  goes here
		one = "yes";
		break;
}
}

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...