Jump to content


Slow down rotation and speed up to same speed before

Go to solution Solved by PointC,

Warning: Please note

This thread was started before GSAP 3 was released. Some information, especially the syntax, may be out of date for GSAP 3. Please see the GSAP 3 migration guide and release notes for more information about how to update the code to GSAP 3's syntax. 

Recommended Posts

Hi NG,


i rotate my DIV 360 deg endless:

tlmenue_ground = new TimelineMax({repeat: -1});

   .to($menue_ground, 15, {rotation:360, transformOrigin:"center", ease:Linear.easeNone},0)


If i click on one button, i will slow down the speed of rotation:

.to($menue_ground, 50, {rotation:360, transformOrigin:"center", ease:Linear.easeNone},0)

And if i click on some other button i will that the speed goes back to first one:

.to($menue_ground, 15, {rotation:360, transformOrigin:"center", ease:Linear.easeNone},0)

But something is wrong with this. If i click more often the speed goes more and more down. Than it stops.


I guess my way is not correct.


Is there some help for me?












Link to comment
Share on other sites

  • Solution



Welcome to the GreenSock forums.


I think rather than trying to change the duration on click, this would be a really good chance to change the timeScale().


Here's a quick pen showing this option in action:


See the Pen VjaXYd by PointC (@PointC) on CodePen


Here's some reading about timeScale()



Hopefully that helps a little bit.


Happy tweening.


  • Like 3
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.