[flashpro] MC onPress within embedded MC onPress ?

Exflux-6 dialectical at gmail.com
Tue Oct 11 19:14:32 EDT 2005


Hey,
 Now I've somehow done this before, but I can't remember how I did it.
I'll sudo-paste the code:

var ob = createEmptyMovieClip('ob', 1 );
with(ob) {
 var sub = createEmptyMovieClip('sub', 2 );
 sub.onPress = function() {
   trace( "Sub-clip pressed." );
 }
}
ob.onPress = function() {
 trace( "Main clip pressed, etc." );
}

The Idea here is to have the MC able to be clicked on and dragged, but
also so that when the clip within the main clip is also pressed, it
does something as well. And I forget how. Granted, the above is
sudo-code. There's more to it than that but 'tis the general idea.

How do I dooooooo this? :)

Thanks, hope the list isn't dead.

-Dial.


More information about the FlashPro mailing list