dcsimg
A Flash Developer Resource Site

Results 1 to 2 of 2

Thread: Buttons... Retaining states and alternate rollovers

  1. #1
    Senior Member
    Join Date
    Jul 2002
    Posts
    150

    Buttons... Retaining states and alternate rollovers

    K... here's a hairy one! I have a menu that I would like to open. When I rollover the title of the menu, it should turn from yellow to blue. When the menu is open, the button should remain blue and when I rollover it, it should turn yellow. When clicked, it should close my menu. I'm using movie clip buttons now with and up, over, down, and hit state. Can I add more states? Do I have to write something else to get this to happen? Thanks!

  2. #2
    Senior Member pellepiano's Avatar
    Join Date
    Feb 2000
    Location
    Stockholm, Sweden
    Posts
    15,151
    A movieclip has no fixed states. A button has four fixed states.

    A "movieclip button" generally means having a button inside a movieclip to control the movieclips timeline ( in which you can define as many animations or "states" as you want.

    Best is to make a framelabel where the diferent states are located and then just fill the button with all the "goto's" needed.

    // Example
    on(rollOver){
    gotoAndPlay("blue");
    }
    on(rollOut){
    gotoAndPlay("green");
    }
    on(release){
    gotoAndStop("newButtonWithActionsAfterClickOnThisO ne");}

    -Pelle Piano
    // Image Gallery
    www.studiobild.com
    // Photo Blog
    http://talesofthepixel.blogspot.com

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