Jump to content

Search In
  • More options...
Find results that contain...
Find results in...

Carl last won the day on April 4 2019

Carl had the most liked content!


  • Content Count

  • Joined

  • Last visited

  • Days Won


Carl last won the day on April 4 2019

Carl had the most liked content!

Community Reputation

9,584 Superhero

About Carl

  • Rank

Profile Information

  • Gender
    Not Telling

Recent Profile Visitors

The recent visitors block is disabled and is not being shown to other users.

  1. Carl

    Pause timiline

    this seems to work https://codepen.io/snorkltv/pen/mdPaggN?editors=1111
  2. Carl

    Pause timiline

    paused() is intended to be used outside of a timeline, not in the middle of it. paused() does not get executed while the timeline is running. Again, my suggestion is to use call() to call a function that evaluates the value of i. https://greensock.com/docs/v3/GSAP/Timeline/call() based on the value of i you can pause the timeline or have it keep playing.
  3. Carl

    Pause timiline

    not exactly. I was thinking you wanted to add the pause when you created the timeline so I would have said if(i){ tl.addPause() } if you want to check to see if a pause is needed while the timeline is running, then I would probably just use call(), but if your way is working, then it should be ok. I'd have to test it myself, which I can't do without a demo.
  4. Carl

    Pause timiline

    Oh and I just remembered I have a blog post showing the most common follow-up question: "How do I pause for a specific amount of time". It's from one of my premium GSAP courses but free below: https://www.snorkl.tv/pause-a-greensock-timeline-for-a-specific-amount-of-time/
  5. Carl

    Pause timiline

    When building the timeline you can test to see if i is true and then use addPause() if yes. See the docs for addPause()
  6. thanks for posting the video, Craig. I actually needed a refresher myself.
  7. Carl

    What is this called?

    Hi @FuzzCod I have an in-depth, free video tutorial on smooth-scrolling and ScrollTrigger's scrollerProxy() that should help you: https://www.snorkl.tv/scrolltrigger-smooth-scroll/
  8. Great idea using GSDevTools! It shows the master is still playing when you call addPause() on the child. the master knows it has 1 more second of animation to play in its child but pausing the child doesn't notify the parent. (pretty sure this is all by design and working correctly) here's a fork with GSDevTools enabled. https://codepen.io/snorkltv/pen/PoNjEEj smoothChildTiming would go on the master... I tried adding it. I don't think it helps in this context. @greensock or @ZachSaucier or someone else would have to advise on a solution.
  9. First it's important to note that things work if you don't nest boxesTL in master. Once you nest, the child timeline gets rendered dependent on where the parent timeline's playhead is. When your delayedCall() runs, the master timeline is already 1 second ahead into the future which forces boxexTL's playhead one second ahead into the future, thus skipping the part where it animates the blue square. Please see this excerpt from the timeline docs https://greensock.com/docs/v3/GSAP/Timeline When a timeline renders at a particular time, it loops through its children and says "okay, you should render as if your playhead is at __" and if that child is a Timeline with children, it does the same to its children, right on down the line. So the playheads generally remain synchronized. When you unpause an animation (resume() or play()), it essentially picks up the playhead and moves it so that its internal playhead is synchronized with wherever the parent's playhead is at that moment, thus things play perfectly smoothly. That is, unless the timeline’s smoothChildTiming is false in which case that child won’t move - its startTime will remain locked to where it was. So basically when smoothChildTiming is true, the engine will rearrange things on the fly to ensure the playheads line up so that playback feels seamless and smooth. The same thing happens when you reverse() or alter the timeScale, etc. - the animation's startTime shifts automatically. But sometimes you might not want that behavior - that’s when smoothChildTiming: false is handy on a parent timeline.
  10. HI Joe, I'm assuming you are using the HTML5 output for ads or something. I have found the animate canvas performance is often worse than what I would get when moving DOM elements around. If I create loops of a hundred or so things moving around I often hit some jank which you would never see with pixi.js or other canvas libs. filters like dropshadow will kill performance. also animate really suffers if you have a large stage / canvas i also found nested symbols to be problematic. I'm no expert on it though, there are probably a dozen more probable causes. Adobe's performance suggestions usually revolve around using spritesheet textures on export.
  11. Hi Hemanta, I believe you may be a student of mine. In GSAP3 Beyond the Basics there is a lesson: Tweening Function-based Values. It will explain how for each target in a tween you can run a custom function to get a unique value. As Richard said, the code in the GreenSock demo is a short and clever way to loop through each panel with very little code. The code loops through each target (panel) and sets a custom zIndex The important thing to understand is that the demo you referenced needs to reverse the stacking order of the DOM elements so that panel "one" is visually stacked on top of "two" and "two" is on top of "three". The demo basically gives the panels these zIndexes Panel | zIndex ONE: 3 TWO: 2 ONE: 1 I made a more verbose version of what the GreenSock demo is doing that adjusts the y value of 4 boxes. It basically displays them in reverse order. Be sure to open up the console and read what is being logged out https://codepen.io/snorkltv/pen/rNeewEG?editors=0011 Also, I have a future ScrollTrigger lesson planned to help beginners demystify what is happening in some of these demos. This was on my list! Hope this helps
  12. beautiful. I had a feeling it was something dumb on my end. Thanks!
  13. Hi, I tried to incorporate Locomotive Scroll by doing a copy-paste job from the demo in the docs. It went pretty well. However, on Chrome and FireFox (mac) you'll see that the scroller-start and scroller-end markers jump vertically. If I set pin:true you will see that car does a similar vertical jitter. I suspect I set something up wrong with the css, but have been staring at it for quite awhile. Would appreciate any help
  14. I'd recommend looping through the headers and creating a tween with a ScrollTrigger for each h1 like https://codepen.io/snorkltv/pen/qBbeyvm?editors=0010 Also you can pass a css string selector into your tweens //not necessary gsap.to(gsap.utils.toArray('h1'), {x:100}) // recommended gsap.to("h1", {x:100}) Also, I believe it's been recommended that the trigger is not the same thing you are animating as it can potentially mess up ScrollTriggers internal calculations of where things are in the viewport. So maybe use each parent div as the trigger.
  15. I decided to release the video and demos as a free tutorial. Check out the video if you need more help understanding how I configure the dynamic repeatDelay https://www.snorkl.tv/greensock-staggers-with-seamless-loops/