Jump to content

Loading movies.


Kasdraven
 Share

Recommended Posts

OK so here is the deal. I'm making a college portfolio and I need to be able to load different movie clips onto a certain part of the stage. The movie clip depends on the button clicked. One, how do I make the movie clip load? And two, how do I make it load at a certain spot on the stage? Thanks in advance for any help.

Link to comment
Share on other sites

OK so here is the deal. I'm making a college portfolio and I need to be able to load different movie clips onto a certain part of the stage. The movie clip depends on the button clicked. One, how do I make the movie clip load? And two, how do I make it load at a certain spot on the stage? Thanks in advance for any help.

If I am not mistaken, you would have to have an emptyMovieClip placed on the stage with specific x, y values (i.e. mov._x = 10 mov._y = 10). This will place your emptyMovieClip on the stage and allow you to load your external swf into it.Try this:// This will load a swf into the emptyMovieClip mov_mc// Don't forget to adjust the x,y property values of mov_mc to your location of choice_root.yourButton_btn.onRelease = function() { loadMovie("your.swf", "mov_mc");};
Link to comment
Share on other sites

  • 1 month later...
OK so here is the deal. I'm making a college portfolio and I need to be able to load different movie clips onto a certain part of the stage. The movie clip depends on the button clicked. One, how do I make the movie clip load? And two, how do I make it load at a certain spot on the stage? Thanks in advance for any help.

Hi, There are two cases, if you are loading a swf ( it is always better to load an external swf if it is for web ) then you can do as other are suggesting ( placing an empty movieclip an then loading external swf to it). And if you are planning to have movieClips in your library and loading it according to the your selection then you can at first create an empty movieclip and place it on the stage at (0,0) and give an istance name, say myEmpty_mc then u can say.
myEmpty_mc.attachMovie("myMc","mynewMC_mc",myEmpty_mc.getNextHighestDepth(),{_x:10,_y:10});

in the above code, "myMC" must be the linkage name of the movie clip to be attached.the x and y position is passed as an object eg : {_x:10,_y:10}

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

×
×
  • Create New...