-
Notifications
You must be signed in to change notification settings - Fork 1.4k
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
Make it possible to change "now" #697
Comments
J00nz
pushed a commit
to J00nz/tween.js
that referenced
this issue
Dec 18, 2024
…n using the "setNow" function.
J00nz
pushed a commit
to J00nz/tween.js
that referenced
this issue
Dec 19, 2024
…Now" functionality.
trusktr
added a commit
that referenced
this issue
Jan 11, 2025
* main: code formatting update tests.yml: use npm ci instead of npm i for reproducible builds Update tests.yml: update setup-node action version Update tests.yml to use the latest LTS version of Node.js #697: Added a section in the user-guide regarding the new "setNow" functionality. #697: Added the ability to override the internal "now" function using the "setNow" function. fix: Fixed error when registered tweens are not completed in order fix: Fixed error when registered tweens are not completed in order test: add test tween unit feature: implement group-level onComplete callback, triggering both group and individual tween completion callbacks
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
As a developer it would be very nice to have a way to override the internal "now" functionality.
I realize that it is possible to send it, or rather "time2, as a argument when invoking methods, but that is a very cumbersome way of doing it.
I propose a way to simply "setNow" that takes a function as a argument and overrides "now" to this.
It would make implementations that modifies the "rate" of time much more convenient to do.
The text was updated successfully, but these errors were encountered: