Jump to content
GreenSock

bat

[solved] How to set the position of an element with motionPathPlugin

Recommended Posts

Hello,

 

like you see i got a spaceship attach to the start of the path, well everything is fine.

 

But i need to center the path element, for that i put in (CSS) comments "transform: translate(387px, 422px);"

So the spaceship is not plug to the path anymore even if i tried to change the coordinate with transformOrigin in GSAP.

 

not sure to entirely understand how it works.

 

hope everything is correctly explain :)

 

edit: I didn't see that we can use viewbox...

See the Pen MWYmwKB by mrfouine (@mrfouine) on CodePen

  • Like 1
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.
×