PDA

View Full Version : Question on my first array....


Electrobaby
03-08-2006, 09:21 PM
Im not sure if my logic is correct here. I have 5 logos mcs with linkage ids as 1-5. I want to list them in an array and have a function grab the next element at the end of the 50 frame animation (which is just a solid color mc that fades in and out to look like the logos are fading in and out.)

So Logo 1 will fade in, stay and while, and then appear to fade out at which time I will call the function. I think the getLogo is a problem...with it I am trying to grab the next element in the array...the elements in the array are the linkage IDs of the logo MCs. Is this all screwed up or what??


var myArray:Array = newArray = ["1", "2", "3", "4", "5"];
var getLogo = myArray++;



function logoSwap() {
_root.attachMovie(getLogo, "nextLogo", 2);
_root.nextLogo._x = 94;
_root.nextLogo._y = 40;
}

thanks all

oldnewbie
03-08-2006, 09:36 PM
This is MX2004 syntax and should thus be moved to the appropriate forum.

Electrobaby
03-08-2006, 09:57 PM
Im not sure if my logic is correct here. I have 5 logos mcs with linkage ids as 1-5. I want to list them in an array and have a function grab the next element at the end of the 50 frame animation (which is just a solid color mc that fades in and out to look like the logos are fading in and out.)

So Logo 1 will fade in, stay and while, and then appear to fade out at which time I will call the function. I think the getLogo is a problem...with it I am trying to grab the next element in the array...the elements in the array are the linkage IDs of the logo MCs. Is this all screwed up or what??


var myArray:Array = newArray = ["1", "2", "3", "4", "5"];
var getLogo = myArray++;



function logoSwap() {
_root.attachMovie(getLogo, "nextLogo", 2);
_root.nextLogo._x = 94;
_root.nextLogo._y = 40;
}

thanks all