i have a site, and as usual there are various buttons, and when a
button is clicked an event action occurs. typically running some kind
of movie clip i have placed on the stage…
my question is…
how would i setup the buttons to play one at a time. i mean. if i have
3 buttons (b1, b2, b3) and lets say b2 was clicked, and that mc was already playing… but the user goes to click b3 instead. how would i script the one mc to close out, and tell flash to play b3’s action? i would like all the buttons to behave in this fashion. if one is running, then upon clicking another button it’s actions would detect another mc was running, and simply close it out before running its own actions.
by the way… each button has an associated mc. for example:
b1 runs b1mc, b2 runs b2mc, b3 runs b3mc. thought this would be useful.
i’m thinking some kind of if/else statement built within the button action would do the trick. for example if b2 was clicked, then the user clicks
on b3.
if b2mc_instance playhead = (frame)
then send playhead to nextframe //close out the current mc
else b3mc_instance.play(2) //runs the b3’s associated mc.
i’m trying to make some thing like this, but my programming skills lacking.
is there some way to do this with action script?
any advice with this would be helpful.
thanks