Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add time to card.throwOut()/ card.throwIn() #22

Open
Moussawi7 opened this issue Dec 12, 2014 · 1 comment
Open

Add time to card.throwOut()/ card.throwIn() #22

Moussawi7 opened this issue Dec 12, 2014 · 1 comment

Comments

@Moussawi7
Copy link

Thanks for this amazing code, it work excellent on mobile devices.
How I can add time when I ThrowOut()/throwIn() a card.
I need to to make something similar to this:

   card.throwOut(100, 500,3000);//where 3000 is the time(ms) that card will take to be in the position (100,500), like in css (transition :3s;)

Thank you again.

@gajus
Copy link
Owner

gajus commented Dec 12, 2014

There is no way to do it due to the nature of the spring physics engine. You could change the tension to adjust the force with which the card is thrown (and thus the time), though that would depend on the throw distance (among other factors).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants