theswordinthemorning -> RE: Flash help and tutorials, come here to share your wisdom or ask questions (1/2/2006 22:50:51)
|
also i got it so that i can load and unload external video clip, even if they are from website, like it is in battleon. here ill give you the code, even if you dont want it 1, put this on a button for the loading of a movieclip. by the way you cant use immages, movieclips etc that have been hosted in a hosting service such as imageshack, you have to upload it to a website or somthing. also it doesnt just have to be movieclips it can be ;a SWF, JPEG, progressive JPEG, unanimated GIF, or PNG file into. If you load an animated GIF, only the first frame is displayed. also if you want mul,tiple loaded movieclips, you have to change my variable tree, to e.g. tree 2, or even piglet on (release) { var tree:MovieClip = createEmptyMovieClip("tree", getNextHighestDepth()); var mcLoader:MovieClipLoader = new MovieClipLoader(); mcLoader.addListener(this); mcLoader.loadClip("http://www.orthlint.bamboohost.com/me.swf", tree); function onLoadInit(mc:MovieClip) { trace("onLoadInit: "+mc); } } 2. put this on the same frame (dont know if thats necessary) on a button. make sure your variable is the same in the loading as the unloading on (release){ unloadMovie(tree); /* or you could use the following, which refers to the movie clip referenced by 'target_mc'. */ //unloadMovie(this); tree.addListener(listenerObject); } 3. now try it :D
|
|
|
|