-
-
Notifications
You must be signed in to change notification settings - Fork 21.3k
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 TRANS_SPRING to Tween #76899
Add TRANS_SPRING to Tween #76899
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I did a quick look into spring tween, but could not find any details about its origin. What I did find is that the formula is similar to the Elastic formula when the spring formula is modified, and that unlike Elastic, the oscillation frequency is accelerated using the cubic of time.
I guessed that the approximate constant was determined to give a good number of about 3 bounds (there may be some additional bounds that are too small to be noticeable) with neat motion, but I don't know what the reason is.
For now, I only review the formulas and leave it to the production team to decide what to do about the license since this algorithm is probably a quote from somewhere.
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think now the behavior and code style are fine.
Well, it is unclear as to the original source of this code. I leave it to the production team to decide if there is a licensing concern.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@KoBeWi How is this cheat sheet generated? It could potentially be improved, like lines could be antialiased and the gaps could be eliminated (there are visible gaps e.g. near zero in elastic). |
With this: https://github.com/wandomPewlin/godotTweeningCheatSheet |
Thanks! And congrats for your first merged Godot contribution 🎉 |
once again:
#58999
sorry, thanks
Bugsquad edited: godotengine/godot-proposals#4212