• This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn more.

Flash Issue with Movie Clips

I'm trying to get back into flash...I learned the basics of it a few years ago and now at work i've been assigned a project to learn flash and produce an interactive "teeth eruption" thing that is basically a timeline where you click different times and it shows what teeth come in at that age. (I work for a dental design company).

I have the setup almost working but I can't remember how to get around this one issue. Basically I have a series of buttons at the bottom that when one is clicked, it activates a movieclip animation showing a tooth fading in and a little box giving a description. Nothing too fancy.

I'm using the script:

on (release){    _root.tooth_mc.gotoAndPlay(2);    _root.tooth_bubble_mc.gotoAndPlay(2);}
to do the task. I have it going to frame 2 so that it doesn't show the teeth before clicking the button.

So basically whenever you click on one button, the animation bringing in the teeth works fine and it stays there...which I want. But when I click another button the animation for that button is activated but the other button's content stays there...so I have two things overlapping each other.

What can I do to tell it that when I click on another button, to remove the old button content?


Junior Member
generally if theres something that you want to make disappear

it would be

movieclip._visible = false;

you could add that code in the same place as the second button to hide the other content, although of course you would perhaps need an entire array of code for each seperate button.

for example

you have 4 buttons

button one would attach code unwantedcontent2._visible = false;
unwantedcontent3._visible = false;
unwantedcontent4._visible = false;

obviously to reverse it you change false to true...

and similar for the others...

I'm just posting a suggestion based on what i'm trying to imagine your project looks like :)

perhaps a screenshot could give a better idea of what you're after?
...provided i havent solved your issue.
Hey thanks for replying! I just tested this out and it seems to have made it work. I've never really worked much with actionscript so I have a lot left to learn, I appreciate the help.


Junior Member
glad i could help ^^

wasnt sure if i had quite the right idea but that was a simple way of getting around it :)

A really awesome book for actionscript, should you require its use in the future... or even just to give you more scope for flash dev if you like:

Foundation ActionScript Animation: Making Things Move! | Book Details [AS2]

it helped me a ton with uni work.

or else the new ActionScript3 version depending on what you're working with :)

Foundation Actionscript 3.0 Animation: Making Things Move! | Book Details

anyway. hope your project works out for you!
Excellent, I think I might pick one of those up. I really need to do some reading on actionscript.

FYI I did finish my project and it turned out great...at least up to par with what my boss was looking for...here is what it looks like:

Dentists4Kids.com - Dental Topics (FAQ)

Nothing special but it gets achieves the goal it was intended for.

Thanks again!