If I have a movieclip that has a class assigned to it and I change a property of that movieclip in code, it seems that the property can no longer be tweened on the timeline.
For example, if my class sets this.x = 100, and later on the timeline I tween the position of the object, that timeline tween will not occur.
Changing either scaleX or scaleY property also seems to stop timeline tweens from happening.
Has anyone else experienced this, and if so, is there a way around it?
I would stick strictly to the as3 code if I were you.
import these at the top of your actionscript
and then set your tween like this:
You have it right. Changing certain properties of an MC on the stage will cause Flash to assume that you are going to position it with script, and tweens will no longer work. A couple of workarounds:
gotoAndPlay
. So for example, if you use script to move the clip on frame 10, and then on frame 20 you dogotoAndPlay(30);
, then a tween at frame 30 will work correctly if you put a blank frame somewhere between frames 20 and 30.