Please - need help using multiple sound channels

Ask a Question related to Macromedia Director Lingo, Design and Development.

  1. #1

    Default Please - need help using multiple sound channels

    Hello Users.
    I am a complete newbie when it comes to Director. I want to create a simple project with sound.
    I have 3 small sound clips: tecno.wav, latin.wav and rock.wav.
    I want to have 3 buttons that say TECNO, LATIN and ROCK. When the user clicks on each button, it plays the sound clip. I want the user to have the option of changing music while he is looking at the presentation. Kind of like a Sound Menu for the user. The user chooses what kind of music he/she wants, then there could also be a stop sound and resume sound button.

    How can I do this? I know there are 8 sound channels. Can I assign each sound clip to it's own channel. I can't have 3 sound files in the score, they have to be internal sound.

    Please help me with this...anyone.




    eyesore webforumsuser@macromedia.com Guest

  2. Similar Questions and Discussions

    1. > 8 sound channels
      Hi all, What are my options with regards to playing more than 8 sounds at a time in a game? I realise that the Mac allows up to 64 (?) channels...
    2. Scrolling sprites in multiple channels
      Hi there, I have sprites in 3 channels that need to scroll together. I was hoping I could use the script I used below for a simple 1 channel...
    3. Merging Multiple Channels
      I have received a file with 8 alpha channels. I need to convert this to a jpg. There is only 1 background layer. When I convert to cmyk or rgb, the...
    4. Adding multiple sound channels in MX
      I'm sure this is a very basic question to most of you, but I can't seem to figure it out.....I need to add an additional sound channel in the score...
    5. sound channels
      I'm newish, and need lots of help. What's the most user friendly way of giving viewers sound options? I have background musictrack plus narration in...
  3. #2

    Default Re: Please - need help using multiple sound channels

    Since you will only be playing one sound at a time, you can use just
    one sound channel. You could control everything pretty simply.
    Something like this attached to each button.

    ----------
    global currentSound

    property thisSprite
    property thisSound

    on getPropertyDescriptionList
    myPropList = [#thisSound:[#comment:"pick the sound file for this
    button:",#format:#sound,#default:"" ] ]
    return myPropList
    end

    on beginSprite me
    thisSprite = me.spriteNum
    end

    on mouseUp me
    -- we'll use sound channel 2 for this example...
    puppetSound 2, 0
    global currentSound = thisSound
    puppetSound 2, thisSound
    end
    -----------

    the sound stop button:

    ---------
    on mouseUp me
    puppetSound 2,0
    end
    ----------

    the play button:

    ---------
    global currentSound

    on mouseUp me
    if currentSound <> VOID then
    puppetSound 2, currentSound
    end if
    end
    -----------

    This can be much more elaborate of course, you can add sound fading and
    mixing to get a smoother transition from one sound to the other, but
    that's a whole different exercise.

    --
    Rob
    _______
    Rob Dillon
    Team Macromedia
    [url]http://www.ddg-designs.com[/url]
    412-243-9119

    [url]http://www.macromedia.com/software/trial/[/url]
    Rob Dillon Guest

Posting Permissions

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

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139