ActionScript 3.0 :: Loading External Sounds?

Jun 30, 2011

I am using this code to load an external mp3 file -

Code:
var snd:Sound=new Sound();
var context:SoundLoaderContext=new SoundLoaderContext();

[code]......

View 1 Replies


Similar Posts:


ActionScript 2.0 :: Loading External Sounds Stored In An Array

Sep 11, 2007

I want to write a function that will load all of my external sounds stored in an array which are just strings of their filenames ie:

var soundList:Array = new Array();
soundList = ["sound1.wav", "sound2.wav", etc];

And create a new array with sound Objects that will have the sounds loaded in them (for later execution). After loading all of the sounds in the soundList array, the function should return or just set a _root value to 'true' ie:

[Code]...

View 1 Replies

Loading Two Different Sounds For One FLV File?

Aug 8, 2009

I need a flv with two sound. I want to load load two different sound for one flv file. For example I want to load my flv file in frame 1 with sound 1 then I want to load my flv file in frame 2 with sound 2. How can I do it?

View 7 Replies

ActionScript 2.0 :: Loading Sounds And Swf's?

May 7, 2002

I have a main movie loading a SoundMC which loads 12 swf's that contain mp3's with preloaders in each swf.

example LoadMovie("swfName","_level10")My issue is that when the swf loads it will load in the top left corner of my movie. So I put it inside of a movieclip and tried to attachMovie("clipname")setProperty._x = x; setProperty._y = x; but no Love. Should I put this in the Main timeline or in the SoundMC timeline or not use it at all?

View 6 Replies

ActionScript 3.0 :: Loading Sounds With Urlrequest?

Feb 4, 2009

this piece of code:

PHP Code:
var mySoundReq:URLRequest= new URLRequest("samplesound.mp3");
var mySound:Sound = new Sound();
mySound.load(mySoundReq);

How does the urlrequest know where that .mp3 file is located, and how do i tell as3 where it is? and another thing: when i put this on the web, how do i locate the file then?

View 6 Replies

ActionScript 3.0 :: Loading Sounds Before Playing?

Jan 16, 2009

There are 8 letters in the menu. Each letter provides a linkwhen clicked and a sound when rolled over. The letters will NOTAPPEAR on stage until their corresponding sound is completedloaded. I did this to avoid distortion during playback. The soundbit are pretty small as well. Anyway, the sounds are still distorted during playback and Idon't know why. They are all MP3. HELP PLEASE!! Here's the scriptfor one of the eight letters (movieclips) only to limit size you'llhave to look through:

public function Index() {
var D:MovieClip = new dMC();
D.x = 100;

[code]........

View 4 Replies

ActionScript 3.0 :: Loading Images And Sounds?

Nov 21, 2010

I made an app. I figured out how to load all my images into in.I have about 1000 images and 1000 sounds that I am using in it. About 70MB of data How will this affect a users computer? Is it even possible the load up this much content?I ask because I am getting stack overload error on my bulkloader!Scares me to think that months of work will go down the drain because I can't load this much data!

View 2 Replies

ActionScript 3.0 :: External SWF Sounds Playing Over Each Other?

Aug 26, 2009

Does anyone have any clue on how to unload an external swf with all its sounds?

View 1 Replies

ActionScript 2.0 :: Importing Sounds From External SWF?

Dec 2, 2005

but I still somehow cant get it to work! I've spent hours surfing around and trying to fix it but I guess I've reached a dead end. This is how my .fla files are.One contains the sound. The .fla is called Track2.fla.In it, I've imported a .wav file and set the Linkage to export for AS and export in first frame. The identifier is "Track2".

on the first frame of the timeline, I added this code:
trackMusic = new Sound(this);
trackMusic.attachSound("Track2");

[code].....

View 2 Replies

Actionscript 3.0 :: Loading Different Sounds With One Sound Object

Jan 9, 2010

I made some sort of MP3 player based on an XML file, and I want to load the next track when pressed on a button. Well that part works, the problem is, when I play the next song, this is what happens:

- The next song plays

- The bar that is normally buffering is already full

- When I skip to a part of the song, it skips to the first song!

How can I "clear" a sound variable and load another one?

View 3 Replies

ActionScript 3.0 :: External Swf Sounds Will Not Stop When Unloaded

Jun 23, 2009

Main swf loads an external swf which has a linear voice-over. User can watch/listen the whole 5 minute piece and then main movie carries on OR User can click to go on without viewing/listening to the whole show. Using removeChild, I can kill the visuals, but the voice track still goes on. i added a SoundMixer.stopAll line, and it does kill the current VO clip, but the next one will play in a few seconds. In the external swf, i'm using timers to delay slide advancement while the voice over plays. Seems like I came across some info that says I cannot fully unload like this with timers in my external swf.

Does this sound like a plausible source of the problem? If so, what is the best way to kill/nullify the timers in the external swf?

View 1 Replies

ActionScript 3.0 :: Using A Button To Stop All Sounds From External SWF?

Nov 16, 2009

I did a search here and I am not sure my question was answered exactly, and even if it was, I wouldn't know it. My problem is going above and beyond what the project calls for. So here we go:I have an external swf that I have loading in when you press a "play" button. Now I need to have a button that stops the sound ONLY on the externally loading swf. I assume from what I have Googled to death that this is called "stopping all sounds". I have also come upon a sound mixer dealy-o, but I'm not sure that is what I am trying to do?????I keep reading about SoundMixer.stopAll (); but this looks to mute the sound all together with no use of a button. So I am ASSUMING that there is more code to add to this when it comes to using a button.

So, I would like to know the EXACT code I need to use to get it working...if at all possible. I named my sound button "btn3_btn" and my mute button "btn4_btn" for now. I want a separate button to turn the sound back on once it has been muted.

View 9 Replies

ActionScript 2.0 :: Removing Delay On External Sounds

Apr 26, 2011

I am building a small quiz in flash, where the user gets a question and 3 answers, that is both shown in text and read as external sound (mp3). I am calling a function to show and read the next answers when the first answer has been read. The text is shown immidately but the sound takes around 6-7 secs. to load......(and it is only 60 kb) how can I avoid this?

My function looks something like this
function readAnswer(){
my_sound=new Sound();
my_sound.loadSound("answer1.mp3",true);
my_sound.onSoundComplete = function() {
trace("answer finish");
//next answer
_root.readAnswer();
}}

View 1 Replies

Actionscript 3 :: Embed Versus Dynamically Loading Sounds?

Jun 4, 2011

It's got 5 tabs, and will give the user the options to play about 10 sounds per tab.I have initially been loading the sounds on runtime, so whenever the user clicked a button to play that sound, I would do something like:

var sound:Sound = new Sound(new URLRequest("assets/hello.mp3"));
sound.play();

I'm not sure, but I don't think this is very good, since I would be loading that sound over and over again if the user pressed the button too many times.

I then thought about embedding the sound in each of the views (I have one view per tab), so would embed the sounds whenever the view was loaded. I think this is a better options, but still am a bit unsure about how the embed works exactly.

[Embed('assets/hello.mp3')] private var hello_mp3:Class;

I suppose it simply embeds the mp3 files when the swf is compiled (making it bigger), but they would not be loaded anymore once the app starts, or once that view is initialized again.

View 4 Replies

Actionscript 3 :: Flash - Sound - Embending External Sounds In The Swf?

Apr 29, 2011

that have more than 200 sounds , so I cannot just put the sounds in my libray in flash and then instanciate them as class and play them. Because the sound it will play when I click one object is not always the same.I have this function to play background sound , where enters the name of the song I wanna to be played :

public function startMusicBack(music:String):void{
var musicback:Sound = new Sound();
var bgChannel:SoundChannel;

[code]....

View 1 Replies

ActionScript 2.0 :: Stop All Sounds With XML Template External Link?

Aug 13, 2009

I have one of these XML driven Flash templates and I have several links that open _blank pages, I would like to stop the background music when they are clicked. I know I need a root stop all function and I think I would then define that function in the <link></link> tag in the XML...

View 0 Replies

ActionScript 3.0 :: Load External Sounds To Be Used For Events In A Game?

Mar 20, 2011

I have a game where sounds are triggered when things happen. These sounds need to be loaded externally so they can be changed. It seems like the sound class is just for loading streaming sound files. Is there a good way to load in these sounds and then have them triggerable and controllable by game events?

View 3 Replies

Actionscript 3 :: Dynamic - Loading/Calling Sounds From String Array?

Mar 7, 2010

i'm attempting to instantiate a bunch of sounds by creating a string array containing each sound's filepath (or name).

var soundByName:Object = {};
var channelByName:Object = {};
var soundName:String;

[code]....

View 1 Replies

ActionScript 2.0 :: Use With Music Is Affecting All Other Sounds - Button Sounds And Background Sound

Apr 16, 2010

I followed the mp3player tutorial (part 3) from [URL] and got it working fine. Only problem is that the setVolume I'm trying to use with my music is affecting all my other sounds - button sounds and background sound. I'm aware of the createEmptyMovieClip/attachSound approach and got it working on my other sounds. But Lee's tutorial-mp3player is using a slight different technique, and so my normal approach doesn't quite work.

[Code]....

View 7 Replies

ActionScript 3.0 :: Synchronize Sounds Perfectly To Do A Kind Of Audio Mixer Using Different Sounds?

Feb 7, 2011

I want to synchronize sounds perfectly to do a kind of Audio Mixer, using different sounds. [URL] does it perfectly, I've been researching and researching and I just don't know how to do it! How does [URL] synchonize audio so perfectly? you can even change sounds and the new ones will come on time! How do I do that? Is it just Action Script? or something else?

View 1 Replies

ActionScript 2.0 :: CS3 Getting Sounds To Start Again After Using Stop All Sounds

Nov 29, 2009

I have a film with 4 scenes in it: Here's a link to the film and as you can see the film does not play the music the second time because of the StopAllSounds function which is probably the wrong code to use. The first scene is just a button with 1 frame, a stop action and a music clip. The second scene is the film. The third scene is the credits fourth scene is a Play again button. I have a Stop all Sounds action on the fourth scene because if I do not use it and I press the Play Again button, the music from the first song keeps playing but also the music from the film starts up again so it starts to play twice. What I want to know is, how do I get the music to stop at the end of the film but start up again once I hit Play Again?

I am using Flash CS3 if that helps and using Actionscript2.

View 2 Replies

ActionScript 3.0 :: Loading External Assets - Screen Stops Until The Loading Is Finished?

Oct 11, 2009

I have a movieclip clip that plays when the movie starts, the movieclip is a visual assets that show's that the application is loading some information but it's not showing any loading progress, just playing while the assets are loaded.I created a for loop that will load the assets using a simple loader, and then when the object is loaded the application push the object to an array.Problem is that when the loading starts all the animation that i have on screen stops until the loading is finished.The whole point is that the animation will play while it's loading.

View 10 Replies

Flash :: Loading / Unloading External SWF Using Buttons From Loaded External Files

Feb 23, 2011

I spent almost a week trying to figure out how to unload a currently loaded swf using its button and loading a new swf... I have three files, a main.fla, file1.fla and file2.fla. In my main.fla, I have a code which loads the other two files. If i will click the "unload" button in the file1.swf, I would like the main.fla to unload the file1.swf and load the other file, file2.swf. Here is the code to load the file1.swf:

[Code]....

View 1 Replies

ActionScript 2.0 :: Loading External XML On An External Server Into Flash Movie When It Is Uploaded

Jun 4, 2004

[FMX] I am having trouble loading an XML file on an external server into my flash movie when it is uploaded. The data loads in fine when the flash file is on my local computer with the xml file on a server. As soon as the flash file is uploaded the XML data will not load in.

View 2 Replies

ActionScript 3.0 :: Loading In And External Swf And Unloading It From A MC Button Inside The External Swf?

Nov 2, 2010

I used to do this fine with AS2 and now i'm struggling to get it to work in AS3.my code is as follows:

PW1.addEventListener( MouseEvent.CLICK,loader1 );
//==================== PS function =============================================
var ldr:Loader = new Loader();

[code].....

View 3 Replies

ActionScript 3.0 :: Loading External SWFs From Another External Swf Into The Main SWF Container?

May 4, 2011

I have created a main "site.swf" file that loads a "default.swf" file into a container after a preloader. On this default.swf file I have buttons that needs to load new external SWF files in its place in the container. All of the external SWFs contain buttons and navigations that will also call up other external SWFs into this container. So, I would like to know how to program each button (some are movieclips as buttons) to unload itself and load the respective SWF into the container (eg. AboutUsButton to call up aboutus.swf into the container). I do not have a main navigation on the site.swf file bacause the navigation changes on each SWF that needs to be loaded into the container.

View 2 Replies

ActionScript 3.0 :: Loading External Pngs And External Text With Html?

Jul 19, 2009

I want to load external png's through this code:

(for this code, check the mcBandPreloader in de .fla file)

Code:
var imageLoader:Loader;
var RespJpeg:String = "images/arch1Proj.jpg"
function loadImage(url:String):void {

[Code]....

Here the problem is that I can't type html in my external txt file. (I did checked the html button in Dynamic Text Properties. What am I doing wrong here?

.fla can be downloaded at [URL]

View 2 Replies

ActionScript 2.0 :: Loading A External Swf Into A Movie - Its Loading Only A Part Of It?

Mar 16, 2004

I'm loading a external swf into a movie everything is fine with that. The only problem is that its loading only a part of it. Does anybody know why? Also, this swf is a mp3 player with streaming. The streaming part works but the playback doesn't.If i start only the mp3 player by itself it's working.here is the fla for the player

View 3 Replies

ActionScript 2.0 :: External Swf Loading Into Target Movieclip Loading

Apr 20, 2005

I'm trying to load a SWF movie into a target movieclip called blankmc. The SWF movie is loaded from an absolute URL (eg. [URL]/img/20042005113934movie3.swf ) My Loading Progress code fails to detect the SWF file size. However the same code works perfectly for a JPG! Essentially the .getBytesLoaded() and .getBytesTotal fail to work. Why is this and how can I get it to work for loading SWFs?

[CODE]...

View 3 Replies

ActionScript 3.0 :: Stop .mp3 And .flv In External Swfs When Loading A New External Swf?

Apr 10, 2009

Specifically, I am building a flash page that loads external swf files and inside some of the external swf  files, I would like to add audio and flash video (flv) streaming from the Flaash Media Server. In some of the external swf files, (using a FLVPlayback component) when you press a button on the main timeline to unload the current playing swf the audio/video continues to play after loading the new external swf file.So I believe that my approach is all wrong and I should be working to dynamically load the .mp3 and.flvs in the external swf ... my questiion is how to unload those assets when loading the new external swf

View 1 Replies







Copyrights 2005-15 www.BigResource.com, All rights reserved