7 Replies Latest reply on Feb 1, 2008 10:36 PM by kglad

    auto play

    Derek Snyder
      I'm customizing a mp3 template and can't figure how to disable the auto play. I believe that I need to alter something in the following AS but I can't figure it out. Any help?

      THANKS!
        • 1. Re: auto play
          kglad Adobe Community Professional & MVP
          comment out theSong.start(0) and

          theSong.loadSound(allSongs
          ["songURL"],true); should be

          theSong.loadSound(allSongs
          ["songURL"],false);
          • 2. Re: auto play
            Derek Snyder Level 1
            THANK YOU kglad!
            works perfectly but now i need the playpause toggle button to display 'play' first not 'pause'.
            i assume changing some 'trues' to ' false' is needed but am having no luck. do i need to adjust the script above or look at another section of the script?
            • 3. Re: auto play
              kglad Adobe Community Professional & MVP
              check the PlayPauseButton timeline. the PauseButton there has its _visible property set to true by default and the PlayButton there has its _visible property set to false by default.

              and/or there is a loop that's checking path.playing and that loop doesn't start until there's a button press.
              • 4. Re: auto play
                Derek Snyder Level 1
                great. So I changed the true/false settings here:

                //playpause buttons
                if (playing) {
                PlayPauseButton.PauseButton._visible = false;
                PlayPauseButton.PlayButton._visible = true;
                } else {
                PlayPauseButton.PauseButton._visible = false;
                PlayPauseButton.PlayButton._visible = true;
                }

                the PLAY is displayed first but when it's hit, the PAUSE doesn't appear. The toggle function isn't working. Further true/false changes here don't seem to engage the toggle action. Hitting PLAY again creates multiple layers of the same some. Quite a messy sound. :)

                My small brain doesn't understand the 'if' statement above. My reading of the original if(playing) statement made it seem as if the old settings should have worked.

                thanks 4 the help.
                • 5. Re: auto play
                  kglad Adobe Community Professional & MVP
                  reset those booleans back to the way they originally were and assign

                  playing = false;

                  below your

                  //theSong.start(0);

                  statement
                  • 6. Re: auto play
                    Derek Snyder Level 1
                    Thank you kglad! Smart, helpful people make my day! My custom player player works great. Appreciate the assistance greatly.

                    The movies are at the bottom of this pg disguised as photos:
                    http://cellocelli.com/SCHOOL/workshops.htm

                    loading is a bit slow so maybe I should edit down the size of the mp3s or put in a preloader for people to see.

                    Thanks again,
                    derek
                    • 7. Re: auto play
                      kglad Adobe Community Professional & MVP
                      you're welcome.