Morning, I am trying to build a timeline using TimelineMax that is just fading elements in and out. I want it to play through the first elements in sequence but then, depending on the number of the current loop, to show a different final frame each time round.
I have set up the simplest example I can in codepen
I wanted the animation to run - red, green, blue, red, green, pink on a loop - but this does not happen.
If the tl.play() on line 20 is set to 'blue' it just never shows the pink element at all and if the label is set to 'pink' it also ignores the blue element every other loop.
I just can't get it to branch as expected so firstly, am I going about this the wrong way or missing something basic?
Secondly, can anyone explain the behaviour I am getting and how I might make it run as I want?
Any details will be gratefully received even if they are not necessarily solutions as I don't really have a good picture in my head of exactly how GSAP runs and I want to understand its general flow better.
Cheers in advance