Rotatng « Operations « Flash Tutorials

Home
Flash Tutorials
1.Actionscript Programming
2.Animals
3.Animation
4.Colors
5.Design
6.Effects
7.Game Cartoon
8.Humans
9.Models
10.Nature
11.Operations
12.Shapes
Photoshop Tutorials
Maya Tutorials
3ds-Max Tutorials
Illustrator Tutorials
GIMP Tutorials
Flash Tutorials » Operations » Rotatng 
onClipEvent (mouseMove) { x = this._xmouse; y = this._ymouse*-1; angle = Math.atan(y/x)/(Math.PI/180); if (x<0) { angle += 180; } if (x>=0 && y<0) { angle += 360; } _root.angletext.text = angle; _root.arrow._rotation = (angle*-1) + 90 }

Creating an animation of an object rotating is very easy to do, whether you do it with tweens or in Actionscript. Unfortunately, sometimes the rotations don't occur exactly how you would want them to, because by default, the anchor for the rotation is the center point of the object being rotated. In this tutorial, you will learn how to change that anchor point for both tweened animations and Actionscript animations.

This tutorial will show you an easy way to create a pseudo 3D rotating globe.

ww__w._j_a_va_2___s___.co_m_ | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.