1 Reply Latest reply on May 14, 2006 8:41 PM by Craig Grummitt

    duplicate movieClip

      can any body say the script required to duplicate a movie Clip many Number of times say for 10 times
      that is a movie clip should be duplicated and i should get some 10 movie clips any all the movieclips should in different places
      if any know the script plz say
        • 1. Re: duplicate movieClip
          Craig Grummitt Level 3
          the following script will duplicate a movieclip named "ball" 10 times with names "ball0", "ball1", "ball2", etc at depth of 0, 1, 2 etc. so that they go to different places i've displayed them at random places on the screen
          for (i=0; i<10; i++) {
          _root.ball.duplicateMovieClip("ball"+i, i);
          _root["ball"+i]._x = Math.floor(Math.random()*400);
          _root["ball"+i]._y = Math.floor(Math.random()*300);