[Okta Webinar] Learn how to a build a cloud-first strategyRegister Now

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 152
  • Last Modified:

slowing down the positioning of a movieclip

Hello,

I have the following code that when the user rollsover a movieclip it goes up or down...the up selection is good...but when I make the movie slide down and it reaches where it is specified..it stays there...which is good but when I move the mouse hight to select something..it goes really fast back up again.  basically I need the movie clip to slide up and down smoothly...when I reach the top I will be able to select things and when I reach the bottom be able to have time to select things...


d = this._ymouse
if(d < 300)d = 300;
if(d > 600)d = 900
arrowY._y += (d - arrowY._y) / delay * 2
menu._y = -150 - ((arrowY._y * 530) / 300)
0
johanwilches
Asked:
johanwilches
1 Solution
 
negatyveCommented:
theBiggerTheFaster = 0.8;
d = this._ymouse
if(d < 300)d = 300;
if(d > 600)d = 600;
arrowY._y += (d - arrowY._y) / delay * theBiggerTheFaster;
menu._y = -150 - ((arrowY._y * 530) / 300)
0
 
johanwilchesAuthor Commented:
thank you negative...

0

Featured Post

Concerto's Cloud Advisory Services

Want to avoid the missteps to gaining all the benefits of the cloud? Learn more about the different assessment options from our Cloud Advisory team.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now