A Flash Developer Resource Site

Results 1 to 7 of 7

Thread: help with koolmoves exchange menu1

  1. #1
    Member
    Join Date
    Aug 2008
    Posts
    78

    help with koolmoves exchange menu1

    Hi,
    Want to thank Bret for his help so far. I've been looking at flash exchange example menu1. It calls up 3 .swfs to play within the stage. Each button calls up one swf. I would like to know if it is possible to stop another swf being played if one is already playing.
    code to play swf
    on(release){
    gotoAndPlay("one")
    mc4.loadMovie("one.swf");
    }
    thanks,
    ja
    Attached Files Attached Files

  2. #2
    Member
    Join Date
    Aug 2008
    Posts
    78
    Anybody? Lots of views but no thoughts?

  3. #3
    KoolMoves Moderator blanius's Avatar
    Join Date
    Jul 2001
    Location
    Atlanta GA
    Posts
    5,244
    hmmm.. confused.
    Your code dosen't quite look right to me. I'm on a computer with out KM so can't test but:
    PHP Code:
    //assuming that you want to load a movie with a filename of one.swf into mc4
    //also this code is AS1 NOT AS3 and in AS3 I believe there is no loadMovie command
    on(release){
        
    mc4.loadMovie("one.swf");
        
    mc4.gotoAndPlay(1);
    }


  4. #4
    Member
    Join Date
    Aug 2008
    Posts
    78

    thanks

    Quote Originally Posted by blanius View Post
    hmmm.. confused.
    Your code dosen't quite look right to me. I'm on a computer with out KM so can't test but:
    PHP Code:
    //assuming that you want to load a movie with a filename of one.swf into mc4
    //also this code is AS1 NOT AS3 and in AS3 I believe there is no loadMovie command
    on(release){
        
    mc4.loadMovie("one.swf");
        
    mc4.gotoAndPlay(1);
    }

    Hi Bret,
    I know its AS1 just found the other code to try to nut it out.
    There are 5 buttons each calls a .swf using
    on(release){
    gotoAndPlay("one")
    mc4.loadMovie("one.swf");
    }
    but I want to only to be able to click on another button if no other .swf is playing - meaning kids can't swap out of one and go to another - must finish one first to move on.

    btw - worked out how to navigate without using enter key by using timers to move to next frame. I sent you a .fun earlier about my problem
    john

  5. #5
    Member
    Join Date
    Aug 2008
    Posts
    78

    menu1 details - is this not possible?

    This is from the flash exchange example menu1. The .fun is uploaded to look at.
    A mc called mc4 is used to call up 3 .swfs to play within the stage. Each button calls up one swf. code to play swf eg
    on(release){
    gotoAndPlay("one") // goes to frame "one"
    mc4.loadMovie("one.swf");
    }

    Is there a way to stop a button loading another .swf if one is already playing?
    thanks,
    ja[/QUOTE]

  6. #6
    Member
    Join Date
    Aug 2008
    Posts
    78

    Just realized its your menu Bret

    Hi all,
    Looks dumb that I'm writing to myself. Just realized Bret, that its your menu1 from the KoolExchange samples. Is there no way a check can be made so that if "one.swf" is running you can't push button 2 and start "two.swf"? At the moment pushing any button stops the current and loads the next.
    AS1 for each button
    on(release){
    gotoAndPlay("one") // or "two" or "three"
    mc4.loadMovie("one.swf"); // or two.swf or three.swf
    }
    I'll drop this thread - just had so many views looks like there are other people interested in finding out.
    thanks,
    John

  7. #7
    KoolMoves Moderator blanius's Avatar
    Join Date
    Jul 2001
    Location
    Atlanta GA
    Posts
    5,244
    I can't imagine why you would want to do this. However you could try this. Firstly I don't think you can tell if a movie is running but you could build the child movies so that they set a variable in the main movie called "running" when they start set it to the clips name or something and on the last frame put the code to set [b]running]/b] to false and in you menu you would do a check for this variable

    So like in mc4 loaded movie you'd put something like
    _root.running=this

    then in the menu you should be able to test the value of running to see if it's not empty....

    The thing is your buttons will not be clickable until a movie stops I would imagine that is NOT what the end user would expect and would probably prove confusing.

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