Jump to content
Search Community

lance1572

Members
  • Posts

    12
  • Joined

  • Last visited

Community Answers

  1. lance1572's post in Restart Timeline was marked as the answer   
    Fixed. Had to enclose in a function and then move the var tl out of the click function.
    j(function(){ var tl = new TimelineLite(); j('.slide a').click(function() { var tri1 = document.getElementById("tri-one"); var tri2 = document.getElementById("tri-two"); var tri3 = document.getElementById("tri-three"); var tri4 = document.getElementById("tri-four"); var tri5 = document.getElementById("tri-five"); tl.add (TweenMax.to (tri1, .25, {opacity: 1})); tl.add (TweenMax.to (tri2, .25, {opacity: 1})); tl.add (TweenMax.to (tri3, .25, {opacity: 1})); tl.add (TweenMax.to (tri4, .25, {opacity: 1})); tl.add (TweenMax.to (tri5, .25, {opacity: 1})); }); j('.info a').click(function() { tl.restart(); }); });
×
×
  • Create New...