Just a heads up.
I’ve recently updated the timer and transition libraries.
The updates added support for tags
to timers. This means that when you create a timer, you can pass a new optional tag
parameter that you can later use to control the all timers that share the same tag
with.
Another new feature is three new function calls for both timer and transition: timer.pauseAll()
, timer.resumeAll()
and timer.cancelAll()
. These are self-explanatory, i.e. they control all timers and/or transitions with one function call.
The final new feature is a new property for the transition library. By default, if you pass nil
or no argument to transition function calls, e.g. transition.cancel()
, then it will affect all transitions. This sometimes leads to issues where the developer passes a reference to a display object to the function after said display object has already been removed. This is the same as passing nil
to the function, so instead of controlling that one display object, all transitions will accidentally be paused/resumed/cancelled.
By setting transition.ignoreEmptyReference = true
, all nil
and empty arguments will be simply ignored instead. After setting this, you may still control all transitions via the three new functions.
To use these new features, you need to download Solar2D 2020.3611 or a newer version.