TeamPhotoshop
Reviews, updates and in depth guides to your favourite mobile games - AppGamer.com
Forum Home Latest Posts Search Help Subscribe

Sound weirdness

Page: 1 Reply
Jul 3rd 2003#111468 Report
Member since: Jun 3rd 2003
Posts: 1867
I don't usually do flash with sounds for some reason, so I started working on a site intro yesterday, and it's got gunshots, heartbeats, the whole 9 yards.

All the sounds are on a separate layer or on separate layers (i.e. all of the heartbeats are on 1 layer, the gun reload sound on another, and the gunshots on yet another).

My question is this;

I found that the sounds are actually triggered (or whatever word you want to use to mean "starting the sound") slower than the movie is playing.

I'm not saying that the actual wav files are playing slower (and thus at a lower pitch) or anything, i'm saying that the wavs are being triggered at slower times, but playing at the right speed.

A good way to imagine it is as if the flash movie and the sound layer was aligned so that the sounds were supposed to trigger at the right times, but as if the sound layer were playing at an fps that's twice the fps of the actual flash movie.

I can still move the sounds later on in the movie (like dragging them to the right in the timeline) and by delaying them in the fla file, I can get them to play at the right time.

This is a bit of a hassle though, and I'm just wondering why the sounds won't play when they should.

I hope you understand this problem; if not, I'll elaborate.

Thanks in advance.


pat
Reply with Quote Reply
Jul 3rd 2003#111476 Report
Member since: Nov 26th 2001
Posts: 2586
Are the sounds being pre loaded?
Reply with Quote Reply
Jul 4th 2003#111555 Report
Member since: May 28th 2003
Posts: 90
How far out are they? are they like 2 or 3 frames out?
Reply with Quote Reply
Jul 9th 2003#112404 Report
Member since: Jun 3rd 2003
Posts: 1867
wow... sorry for not replying.

Marble. there are two layers. the 2nd layer has the whole movie.
The first layer has this as Actionscript:

stop();
ifFrameLoaded("scene 2", 765) {;
play();
}

765 is the last frame in the 2nd scene.

Btw, i'm using Flash MX.



LAV. My sounds are being played too early, so i do have to move them, but I have to move them a LOT. like, 40 frames!!!

And i think it gets longer every time i wnat to put in a sound.

one thing... wtf??? lol
Reply with Quote Reply
Jul 9th 2003#112498 Report
Member since: May 24th 2003
Posts: 212
Originally posted by supahsekzy

stop();
ifFrameLoaded("scene 2", 765) {;
play();
}

765 is the last frame in the 2nd scene.


i'm not sure, but i think if you didnt "play" when the sound has loaded and CHOSE when it plays it'l work. there shud b a pause or something during th movie/animation where any elements (sound or imagery) havent loaded, they do so then, such as preloaders in flash.

i think you problem (even tho sounds weird being a prob) is that the sound is loading quicker than you think it should do.

if you think it should talk 8seconds (10frames a sec) and the sound loads in 4seconds then thats only 40 frames not 80 like you thort.
that way when you move it 40frames forward, theres 40frames left before it needs to play which just happens to be the length of time it takes for that sound to load.

also check what bandwidth simulation u r using in flash when you test it.


you should allow every user to have the same experience in flash so if a 56k'er doesnt hear the sound till the end of the movie but a 512k'er sees it too early, that is NOT providing for every user.


sort it out ! ;) hope that helps


*edit

basically you need to make the sound load. but not play until you say so.

try making a new instance. frame one have a stop command and no sound. then in the main movie load that instance (so the sound is loaded) then do something like;

if (framesLoaded==totalFrames){
goToAndPlay(2)
}

that way if sound isn't loaded it wont play and if it isnt it still wont until u tell it to play .
Reply with Quote Reply
Jul 11th 2003#113017 Report
Member since: Jun 3rd 2003
Posts: 1867
hah, lol i didn't really understand what you said...

but anyway, I used the preloader on this site.

http://www.dzygn.com/forums/viewthread.php?tid=210


The sounds are still at the same thingy as last time.
Reply with Quote Reply
Jul 15th 2003#113682 Report
Member since: May 28th 2003
Posts: 90
Do you have a seperate layer for your sounds in your main movie, and placing a keyframe in the frame where you want the sound to play, select the keyframe and then just drag the sound from the library to the stage and you should find the sound playing everytime those keyframes are played..

Thats how i do it in most cases but there are other ways..
Reply with Quote Reply
Page: 1 Back to top
Please login or register above to post in this forum