Let's say I have an AS2.0 class called myClip, and in my calling script I invoke multiple instances of myClip() objects. Is there any way, within the class itself, to keep track of how many myClip objects have been created?
Currently, I'm doing this in the calling script, by just creating a variable which I increment each time a new myClip is created. But that would cause problems if I destroy a clip and would want to then decrement that value.
It would be so much more convenient if I could create a variable that's "global" across all instances of the class, like the VB "shared" accessor. I believe AS3.0 allows "package" variables which are accessible across the whole package, is that right?
At any rate, is there any way to do this in AS2?