SitePoint Sponsor

User Tag List

Results 1 to 2 of 2

Thread: mc trouble

  1. #1
    SitePoint Member
    Join Date
    May 2003
    Location
    anyplace but here
    Posts
    2
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    mc trouble

    I've seen this before, so I know there's a way...

    Here's my prob:

    Set up my AS for buttons (code below) so a default mc ("begin") would play in main stage when movie loads and when user has rolled out of buttons. However, I need it so user can click on button to view scrollable text or interact with another mc.

    As you can see below, the script the script works too good -- "begin" plays when user rollsOut -- whether they've clicked button or not.

    What's the best way to set it up, so that when the user rollsOut w/o clicking on the button "begin" plays and when the user rollsOut && releases the button "stop" + "SuperText" plays?


    ------------------

    on (rollOver) {
    gotoAndPlay("1open");
    _root.mainStage.gotoAndPlay("stop");
    _root.SuperPlay.gotoAndPlay("SuperGo");
    }
    on (rollOut) {
    gotoAndPlay("1close");
    _root.mainStage.gotoAndPlay("begin");
    _root.SuperPlay.gotoAndPlay("SuperStop");
    }
    on (release) /* I've also tried on (releaseOutside) -- no luck */ {
    _root.mainStage.gotoAndPlay("stop"); /* Also tried gotoAndStop */
    _root.SuperPlay.gotoAndPlay("SuperStop");
    _root.SuperText.gotoAndPlay("SuperText");
    }

    ------------------

    Appreciate it!

  2. #2
    SitePoint Zealot
    Join Date
    Apr 2003
    Posts
    181
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Not sure I understand what you're trying to do because you say "when the user rollsOut && releases the button" - if they've rolled out of the button they can no longer release it.

    However, I think you need something like this:


    on (rollOver) {
    gotoAndPlay("1open" );
    _root.mainStage.gotoAndPlay("stop" );
    _root.SuperPlay.gotoAndPlay("SuperGo" );
    }

    on (rollOut) {
    gotoAndPlay("1close" );

    if(_root.clicked) {
    _root.SuperPlay.gotoAndPlay("SuperStop" );_
    } else {
    root.mainStage.gotoAndPlay("begin" );
    }

    }

    on (release) /* I've also tried on (releaseOutside) -- no luck */ {

    _root.clicked = 1;

    _root.mainStage.gotoAndPlay("stop" ); /* Also tried gotoAndStop */
    _root.SuperPlay.gotoAndPlay("SuperStop" );
    _root.SuperText.gotoAndPlay("SuperText" );
    }


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •