Color testing

hi,

How can I make a condition to test color like for example :
if I have a movie clip whose color is 0xff0000
and I wanna have a condition to test this like :
[AS]
//This is not the right way but how do I doit?
if(_root.MC.color == 0xff0000){
_root.Score = 100;
}else{
_root.Score = 0;
}
}
[/AS]
THANKS:)


blue="0x0000FF"; //this is something I do for clarity

if(_root.mycolor.getRGB()==blue){
        _root.score=100;
}


It didn’t worked (-:

let’s have a look, cause it works perfectly for me :slight_smile:

here is the fla


the condition is in the submit button

The concept is the same, although the answer is slightly more complex because of the naming of movie clips and the method used. It’s not that it is wrong, it is simply that there are many ways to do it.

I’ve attached an example. You can modify at will.

Thanks Iammontoya !!!

:wink:

you’re welcome