FRIHOST FORUMS SEARCH FAQ TOS BLOGS COMPETITIONS
You are invited to Log in or Register a free Frihost Account!


rotation script for flash





sceptileex
Ive been trying to create a flash website. I wanted a picture that would be rotated. I would have one part under mask, and when i rollover a button, the image would rotate, and a different part of the image would rotate into the mask.

My code is like this:
For the main pic:
Code:
onClipEvent(load){
   rot=0;
}
onClipEvent(enterFrame){
   rotation=(rot-_rotation)*.2;
   _rotation+=rotation;
}


For the buttons:
Code:
on(rollOver){
   _root.menu_mc.rot=30;
}


The problem i have now is that the image rotates around the top right corner. The axis is in the top right corner, but i want it in the middle. Can anybody help?
_VMX_
In the top right corner? Isn't it in the top left corner? (that's the default I think)

Anyway, try to select the movieclip, open up the "info" panel in the right, and see the place where you can see 9 squares and you can select one of them as the reference. Try to select the square in the middle centre, and see if it works that way.

See you.
sceptileex
No, it dosent work. Thanks anyway. Anyone else got another method?
Related topics
auto Video File playing Page making script
flash games
Searching for script masters FLASH 8 USERS OR PROGRAMMING
Flash - Photo Gallery - need help please.
[var]websites en flash
Macromedia Flash Action Scripting
How to code Minimise button using action script in Flash?
Anti Tibia and Garfield without flash navs =)
Flash
What programs MUST you have open?
20 - 150 FRIH$ for flash assistance
Ans these Ques
Ans these Ques
List your Firefox extensions
Reply to topic    Frihost Forum Index -> Webmaster and Internet -> Design Tips

FRIHOST HOME | FAQ | TOS | ABOUT US | CONTACT US | SITE MAP
© 2005-2011 Frihost, forums powered by phpBB.