Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 4 of 4

Thread: Sound name help

  1. #1
    New Coder
    Join Date
    Dec 2007
    Posts
    41
    Thanks
    2
    Thanked 0 Times in 0 Posts

    Sound name help

    I been using a video to learn flash and i got a point where i had to type this:

    Code:
    var supersound:Sound = new Sound(???);

    Now the part in brackets is the name of the sound file now this guy says something to do with the name of the clip... now what i was going to put was the sound file like supercollosal.mp3

    But he just puts "super" but no idea where he named the sound file to super for short cos he didn't quite mention it.. i dont see an area to name the sound clip to something i see a box called:

    Frame:
    <Frame Label>

    Which comes up when i click each layer in the properties.. is that what he had done to give it a shorthand name ?

  • #2
    Senior Coder gnomeontherun's Avatar
    Join Date
    Sep 2007
    Location
    Houston
    Posts
    2,846
    Thanks
    10
    Thanked 238 Times in 229 Posts
    I'll cover the bases for you just to make sure you get it all. First you have to first import the sound to the library, and then right click on it and select Linkage. Give it a name of "super" and make sure the export this symbol option is selected. Then to add a sound object you do something like this:

    Code:
    var supersound:Sound = new Sound(this);
    supersound.attachSound("super");
    supersound.start();
    So I believe the step missed is the Linkage issue, so check that.

    You can also read this: http://www.kirupa.com/developer/actionscript/sound.htm
    jeremy - gnomeontherun
    Educated questions often get educated answers, and simple questions often get simple answers.

  • #3
    New Coder
    Join Date
    Dec 2007
    Posts
    41
    Thanks
    2
    Thanked 0 Times in 0 Posts
    My video i have doesn't do that.. he imports them to the library drags it on to the stage with the movie clip it belongs with and just sets it to too loop.. doesn't do any linkage stuff.. is there like different ways to do the same thing basically?

  • #4
    Senior Coder gnomeontherun's Avatar
    Join Date
    Sep 2007
    Location
    Houston
    Posts
    2,846
    Thanks
    10
    Thanked 238 Times in 229 Posts
    Ok so that is essentially the same thing. By dragging it to the stage you are making an instance of the sound object and can label it, but by doing the linkage stuff you are able to access stuff in the library without it being on stage. Same thing, both should get you to be able to access it. Does it work?
    jeremy - gnomeontherun
    Educated questions often get educated answers, and simple questions often get simple answers.


  •  

    Posting Permissions

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