Flash Advisor logo
:: Desktop Shortcut
:: Flash Help
Advice from Experts

+ Reply to Thread
Results 1 to 2 of 2
  1. #1

    Default Sounds Overriding each other on buttons

    Hello all,

    I am very new to flash. As in... Just been using it since the beginning of this semester. We just started sound, and as our assignment, we have to create a sound board with at least 5 different buttons with 5 different sounds.

    My problem is, I'm having no trouble getting -one- sound to play, but when I try to go on to create a second button with an all NEW sound, this newest sound proceeds to override the FIRST sound. (IE: I push the first button, and instead of the sound I assigned it, it plays the sound assigned to button #2.)

    I'm not sure if this is a problem in my timeline or layers, but it's really throwing me through a loop and I cannot for the life of me figure out what's wrong with it. I have tried using the actionscript:

    //creates a variable to hold our new sound
    var log = new Sound(this);
    /*attaches the sound to our variable via the linkage identifer we assigned in the library*/
    log.attachSound("missed_you");
    /*will start the audio playing without input from the user- accepts 2 parameters
    log.start(how long to wait before playing in miliseconds, how many time does the sound play)
    if you DO NOT want the audio to play without user input DO NOT include line 8*/
    //
    /* create 2 buttons on the stage to control the audio playback
    instance name them logStart_btn and logStop_btn
    */
    logStartMissed_btn.onRelease = function()
    {
    log.start(0,1);
    };
    logStopMissed_btn.onRelease = function()
    {
    log.stop();
    Then proceeded to write the same rule just after it (in the same AS box), but with the new instance names for buttons and identifier for sound.

    I have also tried the method of putting the sound directly onto the button timeline (on the 'down' frame), but even THEN it overrides.

    Does anyone have any clue what I'm doing wrong??

  2. # ADS
    Join Date
    Always
    Posts
    Many
     
  3. #2
    Join Date
    Jun 2009
    Location
    Houston, Tx
    Posts
    485

    Default

    Hey man, idk how far you've gotten but I'll give you a little advice. And I know you might not want to hear it, as no one does, but it'll help you out more than just going on forums and asking for different opinions.
    http://help.adobe.com/en_US/FlashPla...e-summary.html
    Figure out how to use the adobe help sites. It's the best place to go and you'll never have to ask around for simple problems again.
    Good luck!

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

     

Tags for this Thread

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
Sponsors
Create Speaking Characters for your website and Flash movies. 15 Day Free Trial