PDA

View Full Version : Probably very simple! please help!


mooowgli
02-12-2003, 09:42 AM
hi and thanks for trying to help me, and many others which i belive have the same problem. Probably its very simple but i cant figur it out. Just downlaod my zipped fla and you will understand my question or read below.

I got three button:s(1-3) and there three mc:s(1-3). Everything lays in one stopped frame on the main stage. The mc:s has different amont of frames but all of them follow the same behavior. The play up to a "turning point" and stop. Then they play the rest of the frames untill the end of the mc "down point".

What i whant to do is. When u push a button1 it should play mc1 up to the mc1:s "turning point" and stop. But if another mc2 already is at its "turning point" it should first play the rest of mc2:s frames until that mc2 reaches its end and then begin to play mc1 from the begining up to its turning point. If u push button1 when mc1 ist on its "turning point" flash should just play the rest of mc1:s frames until it reaches its downpoint.
I would be very glad if the code easy could be used on lets say six mc and there six buttons. But usaly im not so stupid so if u give me the start i should be able to fix that.

//Please just help me with a idea how to begin...

//download my zipped expample fla. and u would get what i mean immediatly.

Thanks again!

adroitemedia
02-12-2003, 03:01 PM
on the button


on (press) {
mc1.gotoAndPlay(2);
// Reapet this next snippet for each movie clip that may need to be ended
ifFrameLoaded ("mc2", 10) {
mc2.gotoAndPlay(11);
}
}

You mat want to make the ifFrameLoaded and external file and use #include for each button.

Let me know if this works!

mooowgli
02-12-2003, 04:02 PM
i'll have to try tomorrow but i'll comeback to u then and let u know how it works.

is ifFrameLoaded the same as currentFrame in that mc?
i have only used ifFrameLoaded for faked preloaders before... but this might work.

thanks for helping me!:D

mooowgli
02-27-2003, 05:01 PM
here is a litte fla that shows what i figured on.

please give me feedback how u could do this easier...

thanks!!!

adroitemedia
02-27-2003, 05:27 PM
i see that it works... very cool idea.. dont know what else your lookin for

mooowgli
02-27-2003, 10:57 PM
oh nothing special. just thouht it would be a very common problem that u what many mc animating up and down, but just one at the time.... and use as litle code as possible.
at least it has bothered me for a while and i did not find any thread that explaind it so i though... might some one could have some use of it. so i attached it!
but i know its not so good code so perhaps someone would care to make it better???

otherwise have a nice day Adroitemedia!

//M