preload using attachSound... a mistake, obviously, but where?
hi!
first: thanks!!! i've found tons of answers for my problems from the earlier threads in different forums, this site is a life saver... but now i need to post a question myself. forgive me if it's a stupid one! i've tried, though, a lot, and need some guidance.
i'm a newbie, struggling to make my first flash site for a band. i found a tutorial describing how to preload sounds. all right, so i decide to practice with that. after trying aaaaalll night, i finally managed to make the preloader work. wheee! well, at least when stimulating download the thingie seems to load my sound files - but how to start the sounds then? i've tried putting different codes to my start-button, according to all advice i've found, but clearly i'm doing something wrong. i know only the very beginnings of action sripting. i'm using flash mx pro 2004.
attached is my tutorial-test.fla... the buttons to start the music are in frame 3. could someone please take a look and point out my error..?
obviously, i'll need buttons to stop the sounds also. since i didn't mange to start them, i didn't proceed that far yet.
lastly, if i may: what i'm aiming at is to eventually have a movie, that preloads and plays 3 to five band's sample songs, each one of them lasting 1 minute. i've already created an animation with musicians actually playing their instruments. i will try to synchronize swf's in different levels so that when a song is loaded and play-button pressed, the animation will move from still image into a band-playing animation loop. when the music stops, the band freezes also. with this aim, am i on the right track...? is this a good method? if not, what should i try next?
i'd really appreciate if someone could help me forward!!!! any advice, hints and comments are more than welcome. it's 8 am now, i've got to get some sleep, i feel like a zombie...
hi!
well, i tried streaming already earlier: i just assigned a sound into the first frame, and chose the option 'stream' from the checkboxes beneath. but when i stimulated download with a bit slower connections, the song sample just kept cutting and hickuping. that's not so good when you're supposed to give a good image of a band, is it... so i thought it would be better for the people to see the preloader first, and then be able to listen to the song completely at one go, without interruptions. did i do something wrong when trying to stream?
thanks,
mar
...a bit more about streaming: now, having tried that a bit more, i found out that the quality of streamed sound is quite poor. with sound forge, i tried improving the quality of the original sound imported into the fla's library: but still, it sounds horrible. plus the hickups are still there. event sound, on the other hand, sounds a lot better even when the mp3 is compressed into a lot smaller size. as it is a site for a band that sells itself with the special sounds of rare acoustic instruments, the sound quality of the sample bits just has to be adequate, doesn't it. so, with my limited knowledge, i fail to get the stream sound clear and functioning enough.
the fla file is still attached in the first message. i haven't been able to solve the problem myself. but it's soooo close, it almost works... i've checked the path to the preloaded sound a hundred times, tried dozend of commands to play it. silence!!!
oh yes: that contains the 2 defined sound objects, which have been imported into the library. i have only one frame in the timeline, containing nothing but the following code:
...woy_sample1 and jamsankoski_sample1 are the names of the example songs i'm using when trying to make this work. their linkage properties should all be correct, as the preloader basically seems to work. so i just wonder where's my error...
You can't test any preloader from your hard drive really. Flash has a test thing, but it's not that accurate. You should really be testing fron online. I don't know why your testing a sound in a swf, cause it's not loading the sound, it's loading the swf with the sound in it. Not the same thing. I think you'll find your answer here;
well, as it happens, i was just reading that faq (again, btw), as i received your message
hmmm... still, i'm a bit at loss now, as i somehow managed to mess up the streaming option as well. now, when i simulate download at lower speed with streamed sound i get no sound at all *huge sigh* ...and just when i thought i'd actually learned something... yeah right. there's nothing like flash to keep you humble. anyway. back to reading...