A Flash Developer Resource Site

Results 1 to 3 of 3

Thread: Click then drag to rotate an object in AS3

  1. #1
    Senior Member
    Join Date
    Oct 2009
    Posts
    112

    Click then drag to rotate an object in AS3

    i know how to make all sorts of sliders and buttons, and I am new yet somewhat familiar with AS3, but rotating an object wiht mouse click and drag has proven more difficult.

    i'm wondering if you can use one of the rotate functions (rotateAroundInternalPoint etc..)

    but i'm not sure how to set it up.

    also can i start out my code like this?

    (assuming the name of my spinning object is "dial")

    dial.addEventListner(MouseEvent.MOUSE_DOWN, spinObject);
    function spinObject(e:Event):void{
    dial.rotateAroundInternalPoint();

    or somethinglike that? anyone familiar with this part of AS3? i've been looking around on google for ages, found a lot of GREAT AS2 examples, but none wiht AS3......

    I think my code is really close but i'm still missing something, any ideas? thanks

  2. #2
    Junior Member
    Join Date
    Jul 2008
    Location
    Leeds, UK
    Posts
    3
    If anybody has any clues on this I would be very grateful of the advice, as I am also looking to achieve a similar thing.

  3. #3
    Junior Member
    Join Date
    Jul 2008
    Location
    Leeds, UK
    Posts
    3
    Scrub that... I've managed to find exactly what I was looking for on the FK Boards. If anybody else is searching for a similar thing you can find it here:

    http://board.flashkit.com/board/arch.../t-799150.html

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  




Click Here to Expand Forum to Full Width

HTML5 Development Center