Hi, i am trying to move several movieclips so have tried to create a loop that should perfrom a tween on all the objects but it dosent seem to work, my code is,
import mx.transitions.Tween;
import mx.transitions.easing.*;
var origYposition:Number = 450;
var duration:Number = 6;
var depth = 0;
var newLocation:Array = ["250","100","280","350","310","220","100","360","140","290"];
function initialisecell() {
for (i=0; i<32; i++) {
var cell = this.attachMovie(["cell"+i], ["cell"+i], depth++);
cell._x = Math.round(Math.random()*980+20);
cell._y = origYposition;
}
}
initialisecell();
for (i=0; i<10; i++) {
new mx.transitions.Tween(cell*, "_y", mx.transitions.easing.Regular.easeInOut, origYposition, newLocation*, duration, true);
}
/*
new mx.transitions.Tween(cell0, "_y", mx.transitions.easing.Regular.easeInOut, origYposition, newLocation[0], duration, true);
new mx.transitions.Tween(cell1, "_y", mx.transitions.easing.Regular.easeInOut, origYposition, newLocation[1], duration, true);
new mx.transitions.Tween(cell2, "_y", mx.transitions.easing.Regular.easeInOut, origYposition, newLocation[2], duration, true);
new mx.transitions.Tween(cell3, "_y", mx.transitions.easing.Regular.easeInOut, origYposition, newLocation[3], duration, true);
new mx.transitions.Tween(cell4, "_y", mx.transitions.easing.Regular.easeInOut, origYposition, newLocation[4], duration, true);
*/
As you can see, the code at the bottom is commented out. This does work but when i try to create a loop for this it wont move any of my movieclips.
PLEASEEEEEEEEEEEEESSSSSSS HHEEEEEEEELLLLLLLLLPPPPPPP!!!