ok i need to be able to create multiple similar sprites/movieclips inside of a for loop
each new sprite/movieclip has to be names according to the number of “i” in the loop
i know how to do it in AS2 but i have searched for methods for doing a similar thing in AS3 to no avail.
here is the code to successfully achieve this in AS2:
for ( var i = 0; i < 5; i ++ ) {
// Create currentThumb MC
var currentThumb = Scroller.allThumbs.createEmptyMovieClip ( "Thumb" + i, i );
currentThumb._x += 10 + ( i * spacing );
// Setting Data for all the thumbs etc
i know that to create movieclips in AS3 you need var MC:MovieClip = new MovieClip and all that
but i need the dynamic names of movieclips
if its possible to have a Sprite container that loads in preset movieclips such as:
//creating many sprites
var sprite1:Sprite = new Sprite()
var sprite2:Sprite = new Sprite()
var sprite3:Sprite = new Sprite()
var sprite4:Sprite = new Sprite()
for ( var i = 0; i < 4; i ++ ) {
// Create currentThumb MC
var currentThumb = sprite + i;
currentThumb._x += 10 + ( i * spacing );
// Setting Data for all the thumbs etc
is there some way of converting this into AS3?
thanks in advance for any assistance