Jump to content
Search Community

onReapeat callback issue

Andy1708
Moderator Tag

Recommended Posts

Posted

Hello

i would like to repat the doHeart function on every blinkEye

So on the blinkEyeTween, i set onStart:doHeart, onRepeat: doHeart

It work onStart but not onRepeat

 

What am i doing wrong ?

 

Thaks

 

 

See the Pen gOpbLwQ?editors=0001 by YVNKAD (@YVNKAD) on CodePen.

ZachSaucier
Posted

Hey Andy. It's best to create the animations at the start and use control method to play them. The way you have it setup it will create a new animation each repeat. I talk more about how to do that in my article about animating efficiently.

 

It also helps you avoid one of the common mistakes of using relative tweens :) 

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