A Flash Developer Resource Site

Results 1 to 4 of 4

Thread: Drop down menu in reverse direction

  1. #1
    Member
    Join Date
    Mar 2003
    Posts
    53

    Drop down menu in reverse direction

    Hi there,

    I found this tutorial on flashkit:
    http://www.flashkit.com/movies/Inter...6369/index.php

    This drop DOWN menu is actually a MOVE UP menu: if you move the mouse over the button1, the sub-buttons appear on screen in an upward direction.

    I'm trying to modify this fla so that it becomes a real drop down menu, with sub-buttons appearing UNDER the main button.

    Now, in the downloaded fla I found this piece of AS:

    stop ();
    if (_root.MCbuttons.MCbutton1._xmouse<-50 || _root.MCbuttons.MCbutton1._xmouse>50 || _root.MCbuttons.MCbutton1._ymouse<-66 || _root.MCbuttons.MCbutton1._ymouse>14) {
    _root.MCbuttons.MCbutton1.play(12);
    } else {
    play ();
    }

    So far I've figured out that the numbers -50, 50, -66, 14 are the boundaries between which the button works. The -50 is the left side of the button, the 50 is the right. The -66 is the topmost boundary of button 1 and the 14 is the bottom of the button.

    My question: what do I have to change on this AS to make my buttons really really drop down? Just change the coordinates to my numbers? Reverse some/all of the > and < operators?
    In my MC, I've already placed my main-button and sub-buttons on the right positions. When I move the playhead, everything appears as it should. Once published, the button doesn't function...

    Any suggestions, plz?

  2. #2
    Senior Member
    Join Date
    Aug 2000
    Location
    Montréal
    Posts
    14,141
    _root.MCbuttons.MCbutton1.play(12);

    this is wrong. play() doesn't take parameters.
    maybe:
    _root.MCbuttons.MCbutton1.gotoAndPlay(12);

    which would suggest a frame based tween animation.

    gparis

  3. #3
    Member
    Join Date
    Mar 2003
    Posts
    53
    Well, the _root.MCbuttons.MCbutton1.gotoAndPlay(12) refers to the closing animation of the sub-buttons. Once you move out of the mouse-boundaries, the MC goes to frame 12, the first frame of the disappearing part of the MC.

  4. #4
    Junior Member
    Join Date
    Jun 2005
    Posts
    3
    I don't know if this will help or not but here's a cool tutorial.

    http://www.actionscript.org/tutorial...ed/index.shtml

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