help with attachMovie and positioning
this is the function I currently call:
code:
function createTemplates():Void {
for (i = 0; i < totalProducts; i++) {
var attachProduct:MovieClip = attachMovie("templateClip", "product" + i, i);
attachProduct._y +=10;
attachProduct._y += i * 230;
}
}
searching..I read several threads..and tried to implement the same "solution"
using "x" & "y" vars for rows & columns... and then running a loop.. through them...however..I am NOT getting the results I want..
either nothing happens...only 1 clips gets attached.. 1 clip nothing is populated..etc..
I like to be able to control the loops through the loop paramters like x<2
& y<10 etc..etc..
here is my last attaempt:
code:
function createTemplates():Void {
for (i = 0; i < totalProducts; i++) {
var attachProduct:MovieClip = attachMovie("templateClip", "product"+ i, i);
for (x=0; x<2; x++) {
for(y=1; y<10; y++){
attachProduct._x = x*50;
attachProduct._y = y*50;
}
}
}
}
I get the LAST clip in my XML file only!! HAHAH
anybody see what Im doing wrong?
thanks