Return to Snippet

Revision: 44263
at April 8, 2011 19:18 by necnova


Initial Code
dx = mouseX - sprite.x; 
dy = mouseY - sprite.y; 
sprite.rotation = Math.atan2(dy, dx) * 180 / Math.PI;

Initial URL

                                

Initial Description

                                

Initial Title
AS3 Rotation with Mouse

Initial Tags

                                

Initial Language
ActionScript 3