# Urgent help : convert Flash4 AS to AS2

**URL:** <https://forum.kirupa.com/t/urgent-help-convert-flash4-as-to-as2/105630>\
**Category:** Uncategorized\
**Created:** [March 28, 2004, 5:52am UTC](https://forum.kirupa.com/t/urgent-help-convert-flash4-as-to-as2/105630 "2004-03-28T05:52:55Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![AndyVasilescu](https://avatars.discourse-cdn.com/v4/letter/a/4da419/32.png) [@AndyVasilescu](https://forum.kirupa.com/u/AndyVasilescu)\
**Post date:** [March 28, 2004, 5:52am UTC](https://forum.kirupa.com/t/urgent-help-convert-flash4-as-to-as2/105630/1 "2004-03-28T05:52:55Z")

</div>

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.

1. 

//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

1. 

//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

1. 

//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
