I’ve come across a rather strange problem with the MovieClipLoader - I have an actionscript file, which simply creates an empty movie clip on the root and loads a movie into it. The root of the movie clip is locked before the swf is loaded.
class loader {
public function loader(n:Number) {
var loader_clip = root.createEmptyMovieClip("test" + n, n);
loader_clip._lockroot = true;
var loaderListener = new Object();
var loadertest = new MovieClipLoader();
loadertest.loadClip(“Circle.swf”, loader_clip);
}
}
All i have for code in my .fla is this :
var one = new loader(1);
var two = new loader(2);
and all I have for code in my loaded Circle.swf is
trace(_root);
Unfortunately, for some reason MovieClipLoader assigns the same root to both clips! For example, when I run my .fla, i get this as a trace:
_level0.test_2
_level0.test_2
when i SHOULD get
_level0.test_1
_level0.test_2
I have absolutely no idea why moviecliploader would act this way…i need to load the same movie multiple times and it has dynamic content, so I need _lockroot to work…any ideas?