dcsimg
A Flash Developer Resource Site

Results 1 to 6 of 6

Thread: Attaching Sound Objects

  1. #1
    Junior Member
    Join Date
    Apr 2004
    Location
    Leicester, U.K
    Posts
    18

    Attaching Sound Objects

    Please help, I think i'm being very thick.

    I am trying to attach sound objects into individual movie clips so that they can be called upon when pressing a button on the main timeline. I want to be able to mute & unmute each sound individually (prefably with a toggle button). At present I seem to be getting nowhere and have looked at every tutorial possible. I must be missing some major concept and as I cannot even get my sound to play correctly yet.

    Please have a look at my test flash file and show me the error of my ways.I've deleted the sound file which is called "myloop" so that the file is small enough to upload.

    Thanks
    Attached Files Attached Files

  2. #2
    Senior Member
    Join Date
    Apr 2004
    Location
    Devon UK
    Posts
    240
    You need to import the sound file you want to play into the library if you want to use attachSound, so import the mp3 to the library first.

    When you have it in, open the library and Right-click on the sound and choose 'Linkage'

    Tick Export for ActionScript
    another tick appears in Export in first frame
    The Identifier box also becomes enabled and takes the name of the object in the library.

    This is the name you need to use in ActionScript to access the sound so change it to 'myloop01' if necessary and it will work without you having to change anything else in your code.

    Good Luck
    Select * From CLEVER_SIGNATURES

  3. #3
    Junior Member
    Join Date
    Apr 2004
    Location
    Leicester, U.K
    Posts
    18
    Tried that and it doesn't seem to work. There must be another problem?

  4. #4
    Senior Member
    Join Date
    Apr 2004
    Location
    Devon UK
    Posts
    240
    post the file with the mp3 in the library if poss...
    Select * From CLEVER_SIGNATURES

  5. #5
    Banned
    Join Date
    Apr 2001
    Location
    Montréal, Québec.
    Posts
    25,397
    Haven't looked at your .fla (Was it in a MX only format anyways, and not MX2004?), but you should have a look at this...

    http://www.kennybellew.com/tutorial/

    And especially at...

    http://www.kennybellew.com/tutorial/independent.htm

  6. #6
    Junior Member
    Join Date
    Apr 2004
    Location
    Leicester, U.K
    Posts
    18

    Hooray. Hooray, Hooray !

    Thanks for your help guys. After reading parts of the Kenny Bellew tutorial for a 100th time I think i've finally twigged. As he say's the grouping is acheived in the way the sound object is defined not by where it is defined. I was defining the sound within a movie clip instead of on the main timeline. I think that was the problem.

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