tommsen Posted March 3, 2010 Share Posted March 3, 2010 hi guys, i have some strange effect, i simply don't get it. i want to rotate to a starting position (in this case 185 degrees), then rotate to 360 within 30 seconds. The strange thing is, that the second tween rotates over the 360 degrees and stops when reaching 360 degrees the second time (rotates faster to do it). If i rotate the first tween to only 175 degrees it works as expected. TweenLite.to(_targetClip, 0, { rotation:185, ease:Linear.easeNone } ); TweenLite.to(_targetClip, 30, { rotation:360, ease:Linear.easeNone } ); any ideas? regards tommsen Link to comment Share on other sites More sharing options...
GreenSock Posted March 3, 2010 Share Posted March 3, 2010 Flash always reports rotation values as being between 180 and -180 (that's just how Flash works). So 185 would technically be reported as -175, therefore the difference between -175 and 360 (your destination) is 535. If you want it to travel a RELATIVE amount of 360, just put quotes around it so that it's a String (TweenLite/Max will interpret Strings as relative instead of absolute - that's a feature, not a bug). Otherwise, just remember that Flash reports rotation between 180 and -180 and build your tweens accordingly. Link to comment Share on other sites More sharing options...
tommsen Posted March 5, 2010 Author Share Posted March 5, 2010 thanks for your resonse! No i don't want it relative. I use it now this way to work around this. Works good for me. if (angle == 360 && _targetClip.rotation < 0) { angle = 0; } Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now