Hi Seb,
If you move the new Array() call into your constructor like so:
import com.seb_lib.utils.Delegate;
class aclass
{
private var target:MovieClip;
private var someObject:Array;
public function aclass(target:MovieClip)
{
this.target = target
someObject=new Array();
init();
}
...it should work.
It's an oddity of AS2 which I don't quite understand (seems to go against
all sense) and I've always vaguely wondered whether it's a compiler bug...
if the variable were marked 'static' it'd make sense. Oh well!
HTH,
Ian
On 10/21/05, quinrou . <[EMAIL PROTECTED]> wrote:
>
> Hi all,
>
> I am having a very odd issue with a class I made. What happens is that one
> of a private variables declare in that class get overwritten when there's
> more than 1 instance of that class. It seems that this var "someObject" is
>
> common to all instances of the class. Which defites the purpose of
> classes.
<snip>
_______________________________________________
Flashcoders mailing list
[email protected]
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders