Scheduler.h
A Scheduler allows for automatic running of logic at certain intervals.
Definition: Scheduler.h:49
bool(*)(void *, Component *component, Entity::ID self, Entity::ID source, const std::vector< std::string > &args) EventHandler
A handler for an event.
Definition: Component.h:132
std::vector< std::string > GetTasks()
Returns a vector of the names of currently running tasks.
Definition: AssetID.h:37
void OnStep()
Function that is called upon each Run iteration. Component Run()s are run before the entity's run fun...
void StartTask(const std::string &name, uint32_t intervalMS, Component::EventHandler task, uint32_t initialDelay=0, void *data=nullptr)
Begins a new task. A task will run once per every announced millisecond interval. The resolution is o...
std::string GetInfo()
Returns a string containing human-readable information on the state of the component.
uint32_t GetTaskInterval(const std::string &name)
Returns the number of milliseconds that the given task is set to.
Class that extends the functionality of an Entity, but as a removable and addable object...
Definition: Component.h:66