So I can load in a movieclip fine, using MovieClipLoader. What I don’t understand is how to access variables in the loaded clip, or, more importantly, how to call a function on the loaded clip.
Here’s what I have as a test:
var game_mc = _root.createEmptyMovieClip("game_mc", 0);
loader = new MovieClipLoader();
loader.addListener(this);
loader.onLoadComplete = function(target) {
trace(game_mc.testnum);
}
loader.loadClip("games/test.swf", game_mc);
testnum is defined as 5 in test.swf by:
this.testnum = 5;
But it comes up as undefined. Is it possible to do this?