Jump to content
Search Community

sharok

Members
  • Posts

    1
  • Joined

  • Last visited

Posts posted by sharok

  1. I have two situations.

    First. For example, we have the following code:

    var timeline = new TimelineMax();
    timeline.to(elem, 1, {css: {boxShadow: '0 0 40px 40px red'}});
    timeline.addCallback(playAudio, 0 ["1.mp3"])) // play audio at begining
    timeline.to(another animation)

    This code starts animation and plays audio. And, I don't know the duration of audio. I need to run `another animation` animation when first animation is completed and callback is completed too. Now it starts when first animation is completed.

     

    Second situation almost the same:

    timeline.addCallback(playAudio, 0 ["1.mp3"])); 
    timeline.addCallback(anotherCallback, 0)); 
    timeline.to(another animation);

    I need to run `another animation` only when all callbacks are finished. 

     

     

     

×
×
  • Create New...