# Adding Sound - Is it taking time to load?

**URL:** <https://forum.kirupa.com/t/adding-sound-is-it-taking-time-to-load/307113>\
**Category:** flash\
**Created:** [March 28, 2010, 6:38pm UTC](https://forum.kirupa.com/t/adding-sound-is-it-taking-time-to-load/307113 "2010-03-28T18:38:55Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![jany](https://avatars.discourse-cdn.com/v4/letter/j/ce7236/32.png) [@jany](https://forum.kirupa.com/u/jany)\
**Post date:** [March 28, 2010, 6:38pm UTC](https://forum.kirupa.com/t/adding-sound-is-it-taking-time-to-load/307113/1 "2010-03-28T18:38:55Z")

</div>

I have built a SoundClass which handles my sound. Any time I want to call upon a sound, I call upon the class and its function. Problem is, there is like a buffering time or something. For instance, when I jump with my character, I am trying to play the jump from the SoundClass I created. It plays, but takes about 3 seconds. Btw, it does this regardless of if its in its own class, or in the same class I am calling it from. The jump.mp3 is only 4KB.

Here is how I have it set up

```auto
package {
	import flash.display.Sprite;
        import flash.events.*;
	import flash.media.Sound;
        import flash.media.SoundChannel;
        import flash.media.SoundTransform;
   	import flash.net.URLRequest;
	
	public class SoundClass extends Sprite {
		private var foxSoundChan:Sound;
		public var jumpSound:String = "MyGame/Sounds/jump.mp3";
		public var request1:URLRequest;
		
		public function SoundClass(){
			request1 = new URLRequest(jumpSound);
			foxSoundChan = new Sound();
                        foxSoundChan.load(request1);
			
		}
		public function jumpS(){
			foxSoundChan.play();
                        trace ("did i jump");//traces immediately
		}
	}
}

```

If I am in another class, I can call upon this by using “soundClass.jumpS();”  
It plays, but takes a few seconds. I have a trace on the function jumpS() and it traces immediately.

Thank you :love:
