Jump to content


  • Posts

  • Joined

  • Last visited

Posts posted by Learning

  1. Hi guys, another timeline question!


    If I have a timeline t1 where some tweens have a delay of 1 second. Am I able to dynamically control this 1 second by passing it in when I'm about to play the timeline again?

    I.e. something like play( delayVar = 1 ) or play( delayVar = 2 ) depending on my needs?
    Or the numbers in the timeline is fixed upon the creation of the timeline?


    Many thanks in advance!

  2. Hi guys,


    I have a timeline which I'm where all my tweens start at 0.

    And one of the tween is a staggerFrom, wondering where do I add the 0 in that case since that location is where the stagger timing is added.


    var t1 = new TimelineMax({ paused: true });
    t1.to( '#scene-3', 1, { scale: 1.2 }, 0 )
       .to( '.side-text', 1, { scale: 1.2 }, 0 );
    I want to add this
    .staggerTo( 'img', 1, { scale: 1.2}, 1 );
    But have it also start at 0. Where should I add the 0?
  3. Very oddly it works when stripped down, but in my file, the 'this' just doesn't register... I wonder what could be the cause...

    Oops, I just found out! It's because I'm adding extra '' to each item. =x Thanks!

    • Like 1
  4. Hi guys,


    I am trying to rotate and scale my header image when the site loads using the following script,


    TweenMax.from( '#myGroup', 6,
    { scale: 0, rotation: 360, ease: Expo.easeOut, transformOrigin: '50% 50%' });
    It works fine except when I refresh the page, it goes off center.
    Apparently checking the source on site, it shows that it stacked two transformations...
    But isn't a refresh of the page supposed to clear and restart things?
    How do I solve this issue?
    It doesn't appear on local, only when it's on the server.
  5. Hi guys,


    Any idea how to set the this keyword to active on self?

    E.g. below, when mouse over, self will rotate?


    $( '#group1', '#group2', '#group3', '#group4', '#group5', '#group6' ).mouseover( function () {

        TweenMax.to( this, { rotation: 360, ease:Expo.easeOut, transformOrigin: '50% 50%'});



    Thanks in advance!

  6. Hi guys,


    Does GreenSock remember the starting value or an object?

    I am currently using +=100, -=100 to handle open close animations, but I realised if I spam click it fast enough, the object will go out of place. If I want the object to reset to its default value after closing, do I have to create a var to store all those values? Is there a way to shortcut/get the starting values?

  7. Hi guys,


    I have a function that makes a tween of my div's y property and a callback at the end of the tween.

    The problem is that sometimes that tween will be called when the property is already at it's end position.

    I would still need the tween to activate the callback after 1 second.

    How should I go about doing this?




    TweenMax.to( $current, 1, {
    y          : -pageHeight * ( u ),
    ease       : Expo.easeInOut,
    onComplete : animationEnds
    But when $current's y is already in place, it calls onComplete immediately. =(
  8. Hi guys!


    Thanks for your replies. Am checking out all the links and learning how it works from there.



    Carl, thanks for your analysis. Yea, I was thinking if there was any way to perform the functions needed for the page piling using only GreenSock. If JS/jQuery is needed either way, then perhaps there's no point to add another lib just for the animation portion since jQuery can handle that too.