Jump to content
Search Community

Set overall timeline play multiplier without dev tools

PG1 test
Moderator Tag

Go to solution Solved by nico fonseca,

Recommended Posts

Hi, 

 

I've spent a lot of time building many animations in a project and would like to run them at 2x in my production app. I've been suing dev tools up until now but obviously won't in prod. 

Wondering if I need to go through and half all timings, or if there is a setting I can use which will allow me to set the timeline play speed somewhere in my code - feels like it would be much easier!

Cheers!

Link to comment
Share on other sites

Advanced tip: if you've got a ton of different animations created (not all in one timeline), you can merge EVERYTHING into one timeline with gsap.exportRoot() which returns a timeline and then you can set its .timeScale() to whatever you want. 

 

You could also control the timeScale of the entire global timeline like gsap.globalTimeline.timeScale(2), for example, but be careful because that affects everything including delayedCalls and everything in the future as well. 

 

If you can just put everything into a timeline and edit its timeScale(), that's probably best. I figured I'd mention some alternatives, though. 

  • Like 1
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.
×
×
  • Create New...