|
-
a simple scripted motion tween question
hi u all!
i found a nice tut about tweening with action scripting, and actually can make some sense of it. hooray! it works. but how could i alter the code so that i can make my object (here figure1_mc) move diagonally instead of straight horizontal/vertical line? the tut explains only how to toggle x or y values separately. ok ok, my cover has blown: i'm pretty new to action scripting, but i'm learning...
here's the code:
var easeType = mx.transitions.easing.Regular.easeOut;
myTween = new mx.transitions.Tween(figure1_mc, "_y", easeType, 0, 300, 30);
so if there's anyone with extra hands out there, i sure could use one now 
manymanythnx, mar
-
Monkey Moderator
if you do a _x tween and a _y tween then you get a diagonal tween.
Code:
var easeType = mx.transitions.easing.Regular.easeOut;
myTweenx = new mx.transitions.Tween(figure1_mc, "_x", easeType, 0, 300, 30);
myTweeny = new mx.transitions.Tween(figure1_mc, "_y", easeType, 0, 300, 30);
www.lexicon-design.co.uk
If we aren't supposed to eat animals, then why are they made of meat?
If Vegetarians like animals so much, why do they eat all their food?
-
i actually tried that earlier, but it wouldn't work for me - now, double-checking i found a mistake in instance names. how typical is that. blind as a bat, me...
thanks, this helps a lot! 
mar
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|