dcsimg
A Flash Developer Resource Site

Results 1 to 5 of 5

Thread: #$%(%)$@!! ColorTransform. Help!

  1. #1
    Senior Member
    Join Date
    Jan 2001
    Posts
    191

    #$%(%)$@!! ColorTransform. Help!

    Ok, here's my code in _root:

    import flash.geom.ColorTransform;
    import flash.geom.Transform;

    myColor = 'FF0000';
    var colorTrans:ColorTransform = new ColorTransform();
    colorTrans.rgb = Number('0x' + myColor);
    var trans:Transform = new Transform(some_random_mc);
    trans.colorTransform = colorTrans;

    This *should* change the color of the movie clip "some_random_mc" to solid red, but instead, I get compile errors saying that the class ColorTransform can't be created. I checked my publish settings, and I do have AS2 and Flash 8 selected. Any ideas?

  2. #2
    Junior Member scudsucker's Avatar
    Join Date
    Feb 2003
    Location
    Cape Town, RSA
    Posts
    1,509
    The obvious question... is the class path correct?
    Hariyemadzisawira nhaka yedu! Down the SCUD and win!
    I'm too lazy to read Private Messages.

  3. #3
    Junior Member scudsucker's Avatar
    Join Date
    Feb 2003
    Location
    Cape Town, RSA
    Posts
    1,509
    Uhm, with Flash 8/Win XP and a movieclip on the stage, your code works as exactly as expected.
    Hariyemadzisawira nhaka yedu! Down the SCUD and win!
    I'm too lazy to read Private Messages.

  4. #4
    Senior Member
    Join Date
    Jan 2001
    Posts
    191
    Yup, it works. My FLA was still stuck in Flash 7 format for publishing, and I SWEAR I set it to AS 2 and Flash 8.... sheesh!

  5. #5

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