Solved

Spinning image in Flash

Posted on 2009-04-01
4
601 Views
Last Modified: 2013-11-12
I'm trying to make a short animation in Flash (CS3 with ActionScript 3), where a graphic will zip around the screen, while spinning, for a few seconds.

I plan to do the zipping around will simple motion tweens. I know I could to the spinning with tweens -- but, would rather do it via Action Script.  Sadly, I'm an Action Script rookie and don't know how to do it.

Help?
0
Comment
Question by:CPOJoe
  • 3
4 Comments
 
LVL 12

Accepted Solution

by:
alien109 earned 500 total points
ID: 24042030
Are you looking to simply rotate the image around it's origin?

If so,

this._rotation += 5;

or

this.rotation +=5;

depending on is your project is a2 or as3
0
 

Author Comment

by:CPOJoe
ID: 24042216
OK - but, need to get basic.
So, I have my image on the stage. I'll do F8 to convert it to a movie clip, right?  Then, do I F9 to put in the code on the MC?
as3, btw.
0
 

Author Comment

by:CPOJoe
ID: 24042418
So, I just clicked in the 1st frame of the main timeline and up the code in there.  I'm getting some rotation -- have to tweak the frame rate, etc to get it to look right.
But, it's rotating around the top, left corner and not the center.  Not sure how to change that...?
0
 

Author Comment

by:CPOJoe
ID: 24042516
Ahh -- OK, Converted the .png to an MC, and put the code on the 1st frame of the MC -- now its rotating around the center...
0

Featured Post

Free learning courses: Active Directory Deep Dive

Get a firm grasp on your IT environment when you learn Active Directory best practices with Veeam! Watch all, or choose any amount, of this three-part webinar series to improve your skills. From the basics to virtualization and backup, we got you covered.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Sometimes you know that one object has a specific child in it, but you can't find the child. This happened to me when I was trying to code some actionScript to make a toolbar work with its embedded buttons.  My partner had created the toolbar usi…
This article provides a case study on how our local youth baseball league deployed a new website, including the platform selection, implementation and benefits to the league.
The purpose of this video is to demonstrate how to integrate Mailchimp with WordPress, by placing a Mailchimp signup form on a WordPress Page or Post. This will be demonstrated using a Windows 8 PC. Mailchimp will be used. Log into your Mailchi…
The purpose of this video is to demonstrate how to set up an RSS Feed on a WordPress Website. This will be demonstrated using a Windows 8 PC. Feedburner will be used for this demonstration. Go to your WordPress login page. This will look like the…

837 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question