10 Replies Latest reply on Apr 9, 2018 2:12 PM by garethghards.co.za

    Load Movie and change size

    shueardm Level 1
      i'm pretty green and like some help.
      I want to load a movie clip and change the dimensions of the clip at the same time- because my main movie is 765X750 and the new clip is smaller. I want the smaller movie to play at it's native x and y size in the projector. I can't work out the script to do it. This is what I have but doesn't change the dimensions when it loads.

      on (release) {
      setProperty("_self", _height, "400");
      setProperty("_self", _width, "600");
      loadMovieNum("intro.swf", 0);


      Thank you.
        • 1. Re: Load Movie and change size
          shikozel Level 1
          you need to load the intro.swf on an empty movie clip and then resize the emtry movie clip. something like that

          var holder=_root.createEmptyMovieClip("holder",_root.getNextHighestDepth())

          // now you can size it
          • 2. Re: Load Movie and change size
            shueardm Level 1
            Hello- thanks for your reply.
            Entering your code below on (release) {

            It doesn't work. I just get the audio from the intro.swf and the other movie stays open at the original size.

            • 3. Re: Load Movie and change size
              ggshow Level 2
              _root.holder._height = 400;
              _root.holder._width = 600 ;
              • 4. Re: Load Movie and change size
                shueardm Level 1
                I'm sorry- that does the same thing, music changes but not movie clip. :(
                Maybe it's my player?
                • 5. Re: Load Movie and change size
                  ggshow Level 2
                  post your fla please
                  • 6. Re: Load Movie and change size
                    shueardm Level 1
                    I can't really do that for copyright reasons but I have figured something out- perhaps you could explain why?

                    My solution which works was to create a swf with the stage properties that I wanted and just one frame with the loadmovie function. So while it looks seamless, it's going from movie1>movie2>intro.swf. I also have to do the same after the intro.swf movie finishes to get back to the larger stage (of course there's another different link swf there too)

                    Man Flash is harder than I thought. :)
                    • 7. Re: Load Movie and change size
                      ggshow Level 2
                      Flash is the easiest among any other software i learned before.
                      Actionscript is the easiest scripting language i learned before.

                      Man... it is harder to understand your question... I still don't get it...

                      May be you just remove the copyrighted content from your fla 1st & post it?

                      Or perhap, if somebody else here can understand shueardm's question?
                      • 8. Re: Load Movie and change size
                        shueardm Level 1
                        hehe. You don't understand the question or you don't understand the solution?

                        Goal: Make CDROM Flash with movie 1 to play and one button in movie 1 to play movie 2 (intro.swf) but movie 2 is smaller stage and I want the stage to shrink otherwise it looks silly.
                        Soluition as explained is to link button to a one frame swf blank stage with the smaller properties and then code that to open movie 2 (which has same stage properties)
                        I'm sure there is an easier way but I have a solution, so thanks.
                        • 9. Re: Load Movie and change size
                          The problem is when you load a SWF, the movieclip you're loading into inherits the properties of the SWF being loaded into it. As loadMovie happens after everything else has processed, resizing the movieclip has no effect as it simply gets reverted to the dimensions of the SWF loading in. What you need to do is run the sizing code after the loadMovie has started and the movie has begun to load.

                          I usually use a loader function that calls another function when it's finished loading. The function can contain _x = ?? & _y = ??. I also hide the loading movie or alpha it to zero and then show it or fade it in when it's finished loading.
                          • 10. Re: Load Movie and change size
                            garethghards.co.za Level 1

                            if you a different .swf file to play in your movie clip by using a button to select which movie, and the movies are all different in size are you wanting to add a code on the button that loads the swf to resize it to fit the movie clip border each time ? whats your solution for pixelation of the picture itself ?