9 Replies Latest reply on Jan 14, 2008 7:52 AM by chrisatflash

    hot to create rows and coloms with attachMovie

    chrisatflash Level 1
      I am trying to read a number for example the number is :
      var amount:Number = 10;

      And what i would like to do now is make coloms 4 and attach a square on the stage.
      So the result would be 10 squares with 4 coloms and 3 rows. (the last row has 2 squares)

      like this:

      X X X X
      X X X X
      X X

      With the for loop i tried something but it fills out 4 times 4 = 16 squares.

      Also is it possible to create an empty movieclip and attach these squares to it? Like an holder?

      I attached an example.. (you have to create an movieclip and call it's linkage Id 'square' )