Jump to content
Search Community

An event (onComplete, onRepeat, etc.) that fires on a yoyo based repeat?

kez1304
Moderator Tag

Go to solution Solved by kez1304,

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

Posted (edited)

Hi guys,

 

Just scratching my head at this.

 

As you can see in my codepen with your console open, all the on[EVENT]s fire, except onRepeat.

 

I'm in need of having an event fire at the end of the repeatDelay on the timeline, but as it stands, I can't find one.

 

Does anyone have any idea how I can find out (and call a function) at the exact moment the text starts to disappear again?

 

 

Many thanks!

 

 

EDIT: Just a note, removing the yoyo and repeatDelay, still means that the onRepeat event doesn't fire... am I missing something obvious here?

See the Pen BjOJee?editors=0010 by anon (@anon) on CodePen.

Edited by kez1304
  • Solution
Posted

D'oh!!

 

It occurs to me now, that onRepeat will have to be called on the TimelineMax itself. The Tween in question isn't aware that it's being reversed.

 

 

Sorry guys!

 

Blonde moment!

  • Like 1

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