A Flash Developer Resource Site

Results 1 to 4 of 4

Thread: Action script in A movieclap within a movieclip

  1. #1
    Senior Member
    Join Date
    Sep 2005
    Location
    Gothenburg, Sweden
    Posts
    357

    Action script in A movieclap within a movieclip

    Hi

    I have this actionscript that i want to ad to a movieclip called "bgcolor" in a movieclip called "main".

    on (release) {
    myColor=new Color(_root.main.bgcolor);
    myColor.setRGB(0x000000);
    }

    My question is: Does it work to write _root.main.bgcolor?

    Thanks guys
    /xzerox... Take a look at http://www.vmgcomputers.com/h75

  2. #2
    Senior Member
    Join Date
    Nov 2006
    Posts
    196
    its like this

    on (release)
    {
    colorchange = new Color("/ball");
    colorchange.setRGB(0x55FF);
    }

    that changes a movie clip from green to blue if you started with a green mc.
    ill post a fun file if u want me to.

  3. #3
    KoolMoves Moderator blanius's Avatar
    Join Date
    Jul 2001
    Location
    Atlanta GA
    Posts
    5,244
    Quote Originally Posted by xzerox_xzerox
    My question is: Does it work to write _root.main.bgcolor?
    That looks fine. or _parent.main.bgcolor will refer to a clip called bgcolor in main in the root or parent timeline.

  4. #4
    Senior Member
    Join Date
    Nov 2006
    Posts
    196
    Heres the source file it works rember that flash is scase sensitive.

    all ur code was right but that works in flash 8 you need to use no big caps in KM only if you need to because it wont work any other way just download the source file =).
    Attached Files Attached Files

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