4 Replies Latest reply on Apr 25, 2006 7:01 AM by kglad

    Theoretical question

    mballom3
      Hi,

      I am trying to build a quizz game, where i show a picture to the player, they have to guess where on the picture i have made some changes (ex a house where i removed on window etc). To achieve this, i simply record the coordinates of the spot where change was applied. When the player clicks the picture if clicked spot's coordinates equals the right one they win and the unchanged picture shows.

      Now the problem is that the quizz movie will be dynamically loaded in another movie. My concern is whether the coordinates are going to change? for example if on one picture the right answer is (5,10), will it remain the same once the movie is loaded?

      If not, how can i do to make it stay the same? I will make a component so that i can produce hundreds of such picture/quizzes, so i better carefully plan ahead than having to make hundreds again lol.

      Thanks for your answers
        • 1. Re: Theoretical question
          Xithis
          Well the easiest way to find out is to try it and see what happens But if I remember correctly about the embedded coordinates, I think they stay the same. Dont have that one project in front of me to check for sure though. Can check later though.
          • 2. Re: Theoretical question
            kglad Adobe Community Professional & MVP
            if your target movieclip has _x and_y properties that match the external movieclip's _x and _y properties (on the external swf's stage), then the coordinates of various parts of the external movieclip will match the coordinates of the corresponding parts in the loaded movieclip.
            • 3. Re: Theoretical question
              mballom3 Level 1
              Kglad,

              Is there a way to make the target movie adopt the size of the loaded swf?

              My pictures will not always have same size so depending on each case the swf size too will change.
              • 4. Re: Theoretical question
                kglad Adobe Community Professional & MVP
                yes, just create an empty target movieclip (createEmptyMovieClip() works well), and it will have the same dimensions (after loading is complete) as the swf/jpg loading into it.