Help! Flash preloaders...
Help! Flash preloaders...
Out of context: Reply #3
- Started
- Last post
- 12 Responses
- unfittoprint0
well you could use a prototype or a class that extends the Movieclip class.
something like [ASS.0]:
Movieclip.prototype.loadObj = function(targetObj,content){
targetObj.loadMovie(content);
this.attachMovie("loader", "loader", 10, {targetObj:targetObj})
}//usage
loadObj(mc1,"movie.swf");you'll have to create a library movie, with a linkage name "loader" [set to export on first frame], with an inside loop where it checks if
(targetObj.getBytesLoaded() == targetObj.getBytesTotal() && targetObj.getBytesTotal() > 10)
//and if so
delete onEnterFrame;
this.removeMovieClip();