Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations derfloh on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

targeting mc array

Status
Not open for further replies.

TheConeHead

Programmer
Joined
Aug 14, 2002
Messages
2,106
Location
US
I am trying to do:

_root.x2.gotoAndPlay(2);

using the vairable "player" for an array of mc's by doing:

eval("_root.x"+_root.player+".gotoAndPlay(2)");

the first (hardcoded works) the second does not....

how should I do that...
 
solution: _root["x"+_root.player].gotoAndPlay(2);
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top