A Flash Developer Resource Site

Results 1 to 3 of 3

Thread: [CS3] Dynamic transition (mask) not working??

  1. #1
    anyone else hear that? flashpipe1's Avatar
    Join Date
    Jan 2003
    Location
    Upstate NY
    Posts
    1,929

    [CS3] Dynamic transition (mask) not working??

    I've got a clip, clipPH2_mc, in a layer. Above that, I've got another clip, clipPH1_mc, and above that, I've got another layer with a placeholder clip, transPH1_mc. In my library, I have a movieclip which is a shape animation, with a linkage name, trans1.

    What I'm trying to do is dynamically make the transition mask clipPH1_mc to reveal it, but it isn't working...any ideas??

    Here's the code:

    Code:
    transPH1_mc.attachMovie("trans1","transPH1_mc");
    clipPH1_mc.setMask("transPH1_mc");
    And I attached the clip...

    THANKS!!!
    Attached Files Attached Files
    Love like you've never been hurt, live like there's no tomorrow and dance like nobody's watching.

  2. #2
    AS3 Mod
    Join Date
    Sep 2007
    Location
    O-H-I-O
    Posts
    2,385
    Try this:
    PHP Code:
    var transPH1_mc:MovieClip _root.attachMovie("trans1","transPH1_mc",1);
    transPH1_mc.cacheAsBitmap true;
    clipPH1_mc.cacheAsBitmap true;
    clipPH1_mc.setMask(transPH1_mc); 

  3. #3
    anyone else hear that? flashpipe1's Avatar
    Join Date
    Jan 2003
    Location
    Upstate NY
    Posts
    1,929
    Thanks for the tip...turns out I was just setting the mask before the attachMovie was finalized...once I switched it to use MovieClipLoader, a listener and onLoadInit, everything works great...

    Thanks!!!
    Love like you've never been hurt, live like there's no tomorrow and dance like nobody's watching.

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