Jump to content
GreenSock

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

Smooth scroll to next panel - too fast

Recommended Posts

3 minutes ago, ZachSaucier said:

Hey Andy,

 

Not sure what you're trying to do. You have two functions that are named the same thing so one is going to override the other. Your if statement is also checking if the element exists, not if the elementIsClicked variable is true or not. Are you trying to do something like this?

 

 

Sorry that duplicate function was an oversight :|

 

I essentially want the click functionality to happen when the link is clicked (which is fine and works), but other stuff to be active the whole time the button is not being clicked (in this case the scrollmagic stuff).

 

Does that make sense?

Share this post


Link to post
Share on other sites

Again, I think that you need to handle that by checking a variable within your ScrollMagic listener like I suggested before. 

 

Unfortunately we don't have the capacity to answer every question not related to GSAP. So you may not get more responses from other members of this forum.

  • Like 1

Share this post


Link to post
Share on other sites

Hey @andystent,

 

Combining ScrollMagic with other scroll processes is not conflict-free - my opinion.
You can remove the SM-scenes and add again (see uncommented lines). But it remains a little 'SM'!

 

See the Pen rNaWvog by mikeK (@mikeK) on CodePen

 

Just tween it using GreenSock.

Mikel

 

  • Like 3

Share this post


Link to post
Share on other sites

Thank you Mikel! I think I can work with this to get the effect I'm needing. Appreciate the help!

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...

  • Recently Browsing   0 members

    No registered users viewing this page.

×