pbjpb
01-10-2002, 03:45 PM
hi jesse! ok i have a quick question about the ecard tut...ok i have some attached MCs that i attach to the _root from diff. drop-down menus. the problem is, bc they are in diff. menus when i add MCs from both they end up replacing each other on the stage. there seems to be something wrong with the depth that the attach action asigns each time it adds a MC to the stage. here is my code for the buttons and the frames that attach the clips, it is the same for each menu:
on the button:
on (press) {
_root.items.push("bas111");
_root.name = _root.items[j]+j;
_root.attachMovie(_root.items[j], _root.name, j+1);
_root[_root.name]._x = 30;
_root[_root.name]._y = 525;
j++;
}
on the frame containing the button:
for (j=0; j<items.length; j++) {
_root.name = items[j]+j;
_root.attachMovie(items[j], _root.name, j+1);
_root[_root.name+"x"] = _root[_root.name]._x;
_root[_root.name+"y"] = _root[_root.name]._y;
}
do you have an idea how i can alter the code above so that it attaches clips without replacing the original ones when i switch between menus? thanks for your help!
on the button:
on (press) {
_root.items.push("bas111");
_root.name = _root.items[j]+j;
_root.attachMovie(_root.items[j], _root.name, j+1);
_root[_root.name]._x = 30;
_root[_root.name]._y = 525;
j++;
}
on the frame containing the button:
for (j=0; j<items.length; j++) {
_root.name = items[j]+j;
_root.attachMovie(items[j], _root.name, j+1);
_root[_root.name+"x"] = _root[_root.name]._x;
_root[_root.name+"y"] = _root[_root.name]._y;
}
do you have an idea how i can alter the code above so that it attaches clips without replacing the original ones when i switch between menus? thanks for your help!