Okay, so what I want is a set of 5 boxes.
I want these boxes arranged 2 per row, so there should be 3 rows in total with the last row only having 1 box in it.
[ ] [ ]
[ ] [ ]
[ ]
Exactly like the above example.
Now I’m doing this by duplicating the 1 mc 5 times, here is my code:
onClipEvent(enterFrame) {
var i = 1
var ctr = 1
while (i < 5) {
if (ctr = 1) {
mctemp = _root.picture1.duplicateMovieClip(i, i);
mctemp._x = 300;
i++;
ctr = 2;
}
else {
mctemp = _root.picture1.duplicateMovieClip(i, i);
mctemp._x = 43;
mctemp._y = 100;
i++;
ctr = 1;
}
}
}
And all I get is out put is the first row of boxes…
ie:
[ ] [ ]
and no more. Can anyone see the error in my code?
Thanks in advance guys,
RaraAvis