Minimum priority level for user scheduling.
Priority level reserved for system services.
Returns time scale of scheduler.
Init the system, will be invoked by Director when registered, should be implemented if needed.
Checks whether a callback for a given target is scheduled.
The callback to check.
The target of the callback.
True if the specified callback is invoked, false if not.
Returns whether or not the target is paused.
Pause all selectors from all targets.
You should NEVER call this method, unless you know what you are doing.
Pause all selectors from all targets with a minimum priority.
You should only call this with kCCPriorityNonSystemMin or higher.
Pauses the target.
All scheduled selectors/update for a given target won't be 'ticked' until the target is resumed.
If the target is not present, nothing happens.
Post update function of the system, it will be invoked after all components late update phase and before the rendering process.
Delta time after the last frame
Resumes the target.
The 'target' will be unpaused, so all schedule selectors/update will be 'ticked' again.
If the target is not present, nothing happens.
Resume selectors on a set of targets.
This can be useful for undoing a call to pauseAllCallbacks.
The scheduled method will be called every 'interval' seconds.
If paused is YES, then it won't be called until it is resumed.
If 'interval' is 0, it will be called every frame, but if so, it recommended to use 'scheduleUpdateForTarget:' instead.
If the callback function is already scheduled, then only the interval parameter will be updated without re-scheduling it again.
repeat let the action be repeated repeat + 1 times, use `macro.REPEAT_FOREVER` to let the action run continuously
delay is the amount of time the action will wait before it'll start
Schedules the update callback for a given target, During every frame after schedule started, the "update" function of target will be invoked.
Modifies the time of all scheduled callbacks.
You can use this property to create a 'slow motion' or 'fast forward' effect.
Default is 1.0. To create a 'slow motion' effect, use values below 1.0.
To create a 'fast forward' effect, use values higher than 1.0.
Note:It will affect EVERY scheduled selector / action.
Unschedules a callback for a callback and a given target.
If you want to unschedule the "update", use unscheduleUpdate()
The callback to be unscheduled
The target bound to the callback.
Unschedules all scheduled callbacks from all targets including the system callbacks.
You should NEVER call this method, unless you know what you are doing.
Unschedules all scheduled callbacks for a given target. This also includes the "update" callback.
The target to be unscheduled.
Unschedules all callbacks from all targets with a minimum priority.
You should only call this with PRIORITY_NON_SYSTEM_MIN
or higher.
The minimum priority of selector to be unscheduled. Which means, all selectors which priority is higher than minPriority will be unscheduled.
Unschedules the update callback for a given target.
The target to be unscheduled.
'update' the scheduler. (You should NEVER call this method, unless you know what you are doing.)
delta time
This method should be called for any target which needs to schedule tasks, and this method should be called before any scheduler API usage.id
property if it doesn't exist.
Sorting between different systems.
System a
System b
Generated using TypeDoc
Scheduler is responsible of triggering the scheduled callbacks.
You should not use NSTimer. Instead use this class.
There are 2 different types of callbacks (selectors):
- update callback: the 'update' callback will be called every frame. You can customize the priority.
- custom callback: A custom callback will be called every frame, or with a custom interval of time
The 'custom selectors' should be avoided when possible. It is faster,
and consumes less memory to use the 'update callback'. *