Skip navigation
Currently Being Moderated

Multiple Movie Clips in a .swf, only one visible

May 13, 2013 5:02 PM

Tags: #swf #images #action_script_3

I have a .fla with many MovieClips. Each MC is a part of a character. For example, I have a MC for the eyes, one for the nose, mouth etc. I then right click on each MC in the flash library and  select 'export as .swf'. This gives me a bunch of seperate .swfs so the user of the game only needs to download the .swfs of the parts for his own character.

 

The MCs are basically only holding a single .png image. However, I now want the user to be able to see a 'close-up' of his face (I don't want to simple scale/zoom for quality reasons). I therefore have two versions of the image, one for displaying on the character (small one) and one for displaying on a close up of the character's face (larger version).

 

Both small and large MovieClips should be packaged into a single .swf, but not both should be visible. How can I best achieve this?

 
Replies
  • kglad
    72,373 posts
    Jul 21, 2002
    Currently Being Moderated
    May 13, 2013 8:49 PM   in reply to RogerDorsey1

    create a new movieclip with the small image in frame one and the larger image in frame 2.  attach a stop() to frame 1.

     
    |
    Mark as:
  • kglad
    72,373 posts
    Jul 21, 2002
    Currently Being Moderated
    May 14, 2013 6:14 AM   in reply to RogerDorsey1

    add frames to a new movieclip that contain whatever you want to display.  if you want to display the small image alone, the small and large together and the large alone, create 3 frames in that movieclip. then export as a swf and whenever you want to display one of the frame of that swf, load it and use a goto (after loading is complete).

     

    i don't see any inefficiency unless it's possible you won't want to use all frames of, for example, the eyes movieclip.  in that case, continue to do what you're doing - create a swf for a small part and a swf for a large part. only load the size/part if needed.

     
    |
    Mark as:

More Like This

  • Retrieving data ...

Bookmarked By (0)

Answers + Points = Status

  • 10 points awarded for Correct Answers
  • 5 points awarded for Helpful Answers
  • 10,000+ points
  • 1,001-10,000 points
  • 501-1,000 points
  • 5-500 points