17 #ifndef HEADER_SUPERTUX_SQUIRREL_SQUIRREL_SCHEDULER_HPP 18 #define HEADER_SUPERTUX_SQUIRREL_SQUIRREL_SCHEDULER_HPP 22 #include <simplesquirrel/vm.hpp> 34 SQInteger schedule_thread(HSQUIRRELVM vm,
float time,
bool skippable);
37 struct ScheduleEntry final
46 bool operator<(
const ScheduleEntry& other)
const 49 return wakeup_time > other.wakeup_time;
56 typedef std::vector<ScheduleEntry> ScheduleHeap;
57 ScheduleHeap schedule;
void update(float time)
time must be absolute time, not relative updates, i.e.
Definition: squirrel_scheduler.cpp:35
This class keeps a list of squirrel threads that are scheduled for a certain time.
Definition: squirrel_scheduler.hpp:26