#include <aurore/core/time.hpp>
◆ ~Ticking()
| virtual aurore::Ticking::~Ticking |
( |
| ) |
|
|
virtual |
◆ isRunning()
| bool aurore::Ticking::isRunning |
( |
| ) |
|
Returns true if the ticking is currently running.
◆ onStart()
| virtual void aurore::Ticking::onStart |
( |
| ) |
|
|
inlineprotectedvirtual |
◆ onStop()
| virtual void aurore::Ticking::onStop |
( |
| ) |
|
|
inlineprotectedvirtual |
Called when the ticking is stopped, either by the user or because it finished.
◆ onUpdate()
| virtual bool aurore::Ticking::onUpdate |
( |
Time |
delta | ) |
|
|
protectedpure virtual |
Executed every frame while the ticking lives. Delta is the time difference in ms between the last frame and the current one. Must return false if the ticking is finished and should be removed from the list of active tickings. The end callback will automatically be called then.
Implemented in aurore::Animatable, aurore::Timer, and aurore::RepeatingTimer.
◆ setEndCallback()
Sets a callback to be executed when the ticking finishes. The callback argument will be set to true if the ticking stopped on its own, false if it was stopped early by the user.
◆ setTickCallback()
Sets a callback to be executed at every tick until the ticking finishes.
The last animation tick will execute the tick callback then the end callback.
◆ start()
| void aurore::Ticking::start |
( |
| ) |
|
Starts the ticking, pushing it to the list of running tickings. If the ticking is finished, it will be restarted. If the ticking is already running, this method will have no effect.
◆ stop()
| void aurore::Ticking::stop |
( |
| ) |
|
Stops the ticking if it was running, and executes the end callback.
◆ updateTickings()
| static void aurore::Ticking::updateTickings |
( |
| ) |
|
|
static |
Called internally by the main loop. Takes all running tickings and updates them.
◆ runningTickings
| std::vector<Ticking*> aurore::Ticking::runningTickings |
|
inlinestatic |
The documentation for this class was generated from the following file: