Hi guys,
I need some help converting some actionscript to actionscript 2.0. It’s really urgent, I’m on a deadline, and time’s really running out. If anyone can help, please get back to me asap, or type your answer here, but please hurry!!
This is from a flash 4 online tutorial…I want to change it so it’ll work in flash mx 2004…please help…
the code is for a rotating menu.
//This will be used later to determine where the mouse is, to change the size and rotation of the menu.
Start Drag (“drag”, lockcenter)
Stop
//this is a rotate clip. The first line determines where the mouse is. The second changes that number so that it is smaller. Line 3 determines the rotation of the menu (‘nav’) and adds xPos/20 to it.
//this is on the first frame of the clip
Set Variable: “xPos” = GetProperty("…/drag", _y)
Set Variable: “xPos” = xPos-150
Set Property ("…/nav", Rotation) = GetProperty ( “…/nav”, _rotation )-(xPos/20)
//this is on the second frame
Go to and Play (_currentframe-1)
//this is for the loop
//a “scale” movie clip.
//Line 1 determines the position of the mouse. The second line checks to see if the mouse is in the closer half of the movie to the menu (the movie width is 400). If this is true, lines 3 - 16 are carried out. Line three reduces x so that the change in the menu’s size is not too drastic. The fourth line checks to see if the new variable is a negative number and if it is then it changes it to positive in line 5. The next 2 lines change the width and length of the menu. The rest of the lines check to see if the menu’s width and height are less than 30 or more than 100.
Set Variable: “x” = GetProperty ("…/drag", _x)
If (x> 200)
Set Variable: “midX” = x - 200
If (midX <0 )
Set Variable: “midX” = - midX
End If
Set Property ("…/nav", X Scale) = midX
Set Property ("…/nav", Y Scale) = midX
If (GetProperty ("…/nav", _xscale) <30)
Set Property ("…/nav", X Scale) = “30”
Set Property ("…/nav", Y Scale) = “30”
End If
If (GetProperty ("…/nav", _xscale)> 100)
Set Property ("…/nav", X Scale) = “100”
Set Property ("…/nav", Y Scale) = “100”
End If
End If
//on the second frame of it … same loop thing
Please help me.
Thanks in advance,
Andy