Jump to content
GreenSock

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

TweenMax Bezier - which segment (value) is current?

Recommended Posts

      TweenMax.to player, len * 2, {
        bezier: {
          values: pathValues
        },
        onUpdateParams: ["{self}"]
        onUpdate: (val) ->
          console.log val
      }

If pathValues is an array 

[{x: 0, y: 80}, {x: 100, y: 200}]

, is there a way to check which value in a path is a current bezier segment?

I have a character that should follow a path and I need it to look forward one step in path, in order to change its animation texture.

 

 

Here's a demo: http://iccthedral.github.io/2014/10/10/PIXI-ex1.html

- Right click on a tile moves the knight (or whatever) to that position.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×