This is another way of rotation related to my previous post
Rotation changes depending on the mousex position
rotator.addEventListener(MouseEvent.MOUSE_DOWN, initialize);
rotator.addEventListener(MouseEvent.MOUSE_MOVE, mouseMover);
rotator.addEventListener(MouseEvent.MOUSE_UP, deinitialize);
var dragging;
var actual_rotation;
var mouse_pos;
function initialize(evt:Event){
mouse_ref = mouseX;
dragging = true;
actual_rotation = rotator.rotation;
}
function mouseMover(evt:Event){
if(dragging){
rotator.rotation = actual_rotation + (mouseX - mouse_pos)* 3;
}
}
function deinitialize(evt:Event){
dragging = false;
}
This movie requires Flash Player 9