1 Reply Latest reply on Jul 14, 2006 1:23 PM by albee

    tween problem

    criminill
      I have posted a simplified version of a problem I have been having at http://www.milestoneadvertising.com/functionTest.fla.
      The problem is that I have a tweening symbol that once a function is executed that specifies the x position for the symbol. I cannot get the tween to start again even though the MC is playing that contains it is playing.

      If you download the source file the tween automatically starts and calls a function (telling it a new x position and stops the animation) once it hits a certain frame in the animation. Then once you hit the button to restart the animation the tween will not start again, but through a trace command you can tell the MC symbol is running.

      Any idea?
        • 1. Re: tween problem
          albee
          A general rule of thumb to follow is, don't mix animating clips with actionscript and animating them with tweens. If you're animating with tweens, stick with tweens (...at least at first). So for this to work have a tween move symbol2 to x = 80, and then have the function be:

          function myFunction() {
          // label a frame "move_to_80" and have the tween animation start there and move to the final position
          symbol1.gotoAndPlay("move_to_80");
          }
          // here is the other function
          function resume() {
          symbol1.gotoAndPlay(1);
          }

          When you DO choose to mix actionscripting with tweening, you need to do it more carefully; it's tough to do this at first, but with practice, you learn what is and is not possible...

          Good luck,

          Albee