A Flash Developer Resource Site

Results 1 to 4 of 4

Thread: Duplicating Objects (Please Enlighten Me)

  1. #1
    Junior Member
    Join Date
    Apr 2002
    Posts
    11
    Hey ... I'm new to flash and just trying to figure a little something out (duplicating objects with actionscript) ... was wondering if I could get a little help.

    I've got a movie, which has one keyframe.
    That keyframe contains the actionscript:
    duplicateMovieClip(_root.circle, "mycircle", 1);
    stop();

    In the library, there is one object, called "circle".
    That object has one keyframe and two layers, "actions" and "image" ...

    The only keyframe in "actions" has the actionscript: stop();
    And "image" contains only a black circle, centered.

    When I run the movie, I get no errors and only a blank white screen ... anybody care to enlighten me why?

  2. #2
    Member
    Join Date
    Apr 2002
    Posts
    76
    hi,
    duplicateMovieClip is not meant to pull out things from library or so i presume. the solution to your problem would be .

    right click on the library item you have . i think it is circle .

    you'll see a linkage option.

    in that select the export this symbol option.

    give it a new name say 'circle1'

    and in the first frame put this.

    _root.attachMovie("circle1","mycircle",1);


    this should work

    bye
    Venkat

  3. #3
    Junior Member
    Join Date
    Apr 2002
    Posts
    11
    Thanks

    Is this the standard way of creating sprites?

  4. #4
    Member
    Join Date
    Apr 2002
    Posts
    76
    cool man... ya this is my standard way of creating sprites... I guess you are from the world of Director

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  




Click Here to Expand Forum to Full Width

HTML5 Development Center