PDA

View Full Version : need help with actions[FMX]



rogerio26
August 12th, 2003, 11:32 AM
//I would like that the movie clip "resu_mc"
be with _alpha = 100 after the movie clip
"mask_mc" has the height 700.
//I trieded the code bellow and it's nothing working. the _alpha continuos zero.
//Thanx in advance.
Rogerio

mask_mc.onEnterFrame = function() {
if (mask_mc._width < 900) {
mask_mc._width += 50;
}else{
if (mask_mc._height < 700)
mask_mc._height += 50;
}
};
resu_mc.onEnterFrame = function() {
dm = getProperty("/mask_mc", _height);
if (Number(dm) == 700) {
resu_mc._alpha = 100;
}
};

blah-de-blah
August 12th, 2003, 11:44 AM
You should use the AS tags next time :) but from what i can see so far, i don't think you should do <900 and <700, because it would be confusing :-\ I also see you are using getProperty which is old and everything. You should change that to:

dm = _root.mask_mc._height

and i do'nt think you need Number(dm). Just use dm...

That should be it :)


ok i'll try and write it all out for you since what i said might have been confusin :) I don't know if this will solve the problem though, it should...


mask_mc.onEnterFrame = function() {
if (mask_mc._width < 900) {
mask_mc._width += 50;
}
}
resu_mc.onEnterFrame = function() {
dm = _root.mask_mc._height
if (dm > 700) {
resu_mc._alpha = 100;
}
}


That should work, havn't tested it though. You havta make sure mask_mc is on _root, or else you have to change the code a bit :)