class flixel.addons.plugin.taskManager.AntTaskManager extends FlxBasic
Available on all platforms
The Task Manager is used to perform tasks (call methods) in specified order. * Allows you to quickly and easily program any action, such as the appearance of the buttons in the game menus. * Task Manager is started automatically when you add at least one task, and stops when all tasks are done. * * @author Anton Karlov * @author Zaphod *
Instance Fields
function addInstantTask(Function:Void ->Bool, ?IgnoreCycle:Bool = false):Void
Adds a task to the end of queue, the method will be executed only ONCE, after that we go to the next task. * *
Function | Method-task to be executed in sequence. * |
IgnoreCycle | If true then the task will be deleted from the manager immediately after execution. |
function addPause(Delay:Float, ?IgnoreCycle:Bool = false):Void
Adds a pause between tasks * *
Delay | Pause duration * |
IgnoreCycle | If true, the pause will be executed only once per cycle |
function addTask(Function:Void ->Bool, ?IgnoreCycle:Bool = false):Void
Adds a task to the end of queue, the method will be executed while it returns false. * The task will be completed only when the method will return true. And manager will switch to the next task. * *
Function | Method-task to be executed in sequence. * |
IgnoreCycle | If true then the task will be deleted from the manager immediately after execution. |
function addUrgentInstantTask(Function:Void ->Bool, ?IgnoreCycle:Bool = false):Void
Adds a task to the top of the queue, the method will be executed only ONCE, after that we go to the next task. * *
Function | Method-task to be executed in sequence. * |
IgnoreCycle | If true then the task will be deleted from the manager immediately after execution. |
function addUrgentTask(Function:Void ->Bool, ?IgnoreCycle:Bool = false):Void
Adds a task to the top of the queue, the method will be executed while it returns false. * The task will be completed only when the method will return true, and the manager will move to the next task. * *
Function | Method-task to be executed in sequence. * |
IgnoreCycle | If true then the task will be deleted from the manager immediately after execution. |
function nextTask(?IgnoreCycle:Bool = false):Void
Move to the next task * *
IgnoreCycle | Specifies whether to leave the previous problem in the manager |
function onComplete():Void
This function will be called when all tasks in the task manager are completed