Jump to content

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


  • Posts

  • Joined

  • Last visited

About lzy100p

lzy100p's Achievements

  1. The object in Draggable does not listen to the mousedown event, but the click and touch events are fine。 How to listen to the mousedown event? Thanks
  2. Still wish there was a render method,Very helpful for me One more problem was found when upgrading the old project: Tween does not overwrite the previous Tween very well https://codepen.io/lzy100p/pen/XWaQKpx In gsap2 it will stop after 1 second This is very different from gsap2
  3. Thank you very much for your advice, the previous project was done with the old version, recently trying to update to the new version I don't like to use fromTo because it will start the movement immediately In some complex timelines I usually initialize the objects all at the beginning as they were at the beginning, and then use them later in the timeline like this If I switch to the new version do I have to add intermediateRender on every line or just on the first line? thanks
  4. https://codepen.io/lzy100p/pen/eYEXLRN Is that how it should be used? It doesn't seem to be working The first frame is not rendered var tl = new TimelineMax({immediateRender:true,repeat:-1,paused:true}) tl.to(div,0,{autoAlpha:0}) tl.to(div,2,{autoAlpha:1}) tl.play()
  5. immediateRender is useful,Thanks
  6. The timeline.render(0) in the old version is gone in the new version。 I found an alternative way: timeline.seek(1) timeline.seek(0) But this way it looks like it renders twice,In my project there are a lot of animations and rendering them twice may cause lag Is there an alternative to render in the new version? Thanks
  7. hi, I am an old user, I have been using the old version 2.0 before。 I need to migrate my project to 3.0,I found some problems TweenMax.to(d1,"1",{x:110}) //Writing it this way will throw an error:Uncaught TypeError: Cannot use 'in' operator to search for 'duration' in 1 //2.x No problem gsap.to(d1,{x:110,duration:"1"}) //No problem writing with gsap It's not a big deal, but it's not compatible with the old project, but hopefully it will behave consistently like the old version thanks gsap v:3.6.0
  8. ClipPath animation doesn't work on the IOS12 var tl1 = new TimelineMax({repeat:-1,paused:true}) tl1.to(div1,0,{webkitClipPath:"polygon(0px 0px,0px 100px,100px 100px)"}) tl1.to(div1,1,{webkitClipPath:"polygon(100px 0px,100px 100px,200px 100px)"}) tl1.render(0) tl1.play() codepen: https://codepen.io/lzy100p/pen/oKwMaY
  9. After running killTweensOf(), change the properties autoAlpha. It does not work. killTweensOf() is in the onComplete. i use 2 tweens,because I want to use different ease http://codepen.io/lzy100p/pen/bgRVVW
  10. var d1=document.createElement("div") document.body.appendChild(d1) d1.style.left="0px" d1.style.top="0px" d1.style.width="100px" d1.style.height="100px" d1.style.position="absolute" d1.style.background="#ff0000" var p3to=new TimelineMax({repeat:-1,paused:true}) p3to.to(d1,1,{autoAlpha:1,physics2D: {angle: 0,velocity: 300,gravity: 500}}) p3to.to(d1,0.3,{autoAlpha:0},"-=0.3") p3to.render(0) p3to.play() it will throw an error Uncaught TypeError: Cannot read property 'length' of undefined