uli-b
02-22-2009, 09:53 AM
Hello everybody,
I am currently working on a flash project that consits of two different fla files. I would like to instantiate numerous instances of fla2 inside fla1 and hence tried the following but it didn't work:
inside fla1.fla:
var instance:fla2 = new fla2();
addChild(instance);
inside fla2.as:
public class fla2 extends MovieClip {
public function classic_memory_editor(){
super();
}
}
When I run the code above, an instance of fla2 is added to fla1. But the Problem is, that the contents of fla2.fla are not added to fla1 because fla2.as of course does not know about fla2.fla... hard to understand - I hope someone out there gets what I mean...
So how can I instantiate one flash file inside another?
Thanks and best regards,
Uli
I am currently working on a flash project that consits of two different fla files. I would like to instantiate numerous instances of fla2 inside fla1 and hence tried the following but it didn't work:
inside fla1.fla:
var instance:fla2 = new fla2();
addChild(instance);
inside fla2.as:
public class fla2 extends MovieClip {
public function classic_memory_editor(){
super();
}
}
When I run the code above, an instance of fla2 is added to fla1. But the Problem is, that the contents of fla2.fla are not added to fla1 because fla2.as of course does not know about fla2.fla... hard to understand - I hope someone out there gets what I mean...
So how can I instantiate one flash file inside another?
Thanks and best regards,
Uli