Reputation: 520
I have placed two movieclips one parent name "container" and a child inside container named holder. I want container to rotate by pressing/dragging the holder placed at the top right corner with mouse movement. The container should rotate from the center point.
Upvotes: 0
Views: 103
Reputation: 13809
Here on Stack Overflow, we do not work for you and code for you. We just answer productive questions that will help future users.
So what you would do is make a MouseEvent function and add the event to holder by container.holder.addEventListener(MouseEvent.MOUSE_CLICK...)
and in the function you would put: addEventListener(Event.ENTER_FRAME...)
and in that enter frame event, you would put: event.currentTarget.rotation += NUMBER
or container.rotation += NUMBER
- Same Thing because the event's current target is container
. Replace NUMBER
with a number.
Not much is being done here, as you can see:
Upvotes: 0