Tweeny
3
A Tweening library for modern C++
|
◆ onStep() [1/3]
Adds a callback that will be called when stepping occurs, accepting both the tween and its values. You can add as many callbacks as you want. Its arguments types must be equal to the argument types of a tween instance, preceded by a variable of the tween type. Callbacks can be of any callable type. It will only be called via tween::step() functions. For seek callbacks, see tween::onSeek(). Keep in mind that the function will be copied into an array, so any variable captured by value will also be copied with it. If the callback returns false, it will be called next time. If it returns true, it will be removed from the callback queue. Example:
|