View Full Version : [AS2] onClipEvent help

06-27-2010, 04:57 AM
First off, I'm new at making games, and whenever I try putting in a code that involves onClipEvent it says that clip events are only permitted for movie clip instances, is there something I'm missing here? I convert all my object to movie clip symbols and I check export for action script and export in frame one. yet apparently my symbols aren't movie clips...

what do I need to do to make my symbols movie clip instances?

06-27-2010, 07:55 AM
You're maybe setting the code on a frame action rather than on the clip itself.
What does the actions window's title say? Actions - Frame or Actions - Movie Clip?

06-29-2010, 02:55 AM
it says actions - frame
is that what's wrong?

if so, how would I go about changing that?

06-29-2010, 03:32 AM
When you use a frame action, you would reference the targeted movie clip by it's instance name, and use something like...

some_mc.onEnterFrame = function(){
// Your code here...

If you're setting the code on the mc itself, then right-clicking that mc on stage and hitting Actions, should open up the Actions - Movie Clip window, which is where you should be typing your script...

// Your code here...