Task FunctionsSummary | | | Schedule execution of a game task. | | Remove a scheduled game task. | | Schedule execution of a player task. | | Remove a scheduled player task. | | Schedule execution of a room task. | | Remove a scheduled room task. | | Schedule execution of a replica task. | | Remove a scheduled replica task. | | Check for any pending tasks and run the first one found. | | Checks whether a task with the given name has been defined. | | Executes a task directly. | | Search the list of game tasks. | | Search the list of player (node) tasks. | | Search the list of room tasks. | | Search the list of replica tasks. | | Returns the number of ticks until task fire. | | Returns the number of ticks until task fire. | | Returns the number of ticks until task fire. | | Returns the number of ticks until task fire. |
game_taskSchedule execution of a game task. A game task is used for any task not associated with any specific internal database record. The id given when scheduling the task will be available in <game.task_object> when the task finally executes. Paramsid | the id to associate with this | task$ | name of the task to schedule | when | centi-seconds until first fire | repeat | repeat in X centi-seconds | group | a numeric group id (currently unused) |
Returnsnothing
clear_game_taskRemove a scheduled game task. Use this to prevent a scheduled task from executing. All tasks scheduled for the given id and name combination will be removed. If id is 0, then all tasks matching the given name will be removed. Paramsid | the id to associate with this | task$ | name of the task to schedule |
Returnsnothing
player_taskSchedule execution of a player task. A player task is used for a player (or node) and is automatically deleted if that record becomes invalid (or logs off). Paramsid | the id to associate with this | task$ | name of the task to schedule | when | centi-seconds until first fire | repeat | repeat in X centi-seconds | group | a numeric group id (currently unused) |
Returnsnothing
clear_player_taskRemove a scheduled player task. Use this to prevent a scheduled task from executing. All tasks scheduled for the given id and name combination will be removed. If id is 0, then all tasks matching the given name will be removed. Paramsid | the id to associate with this | task$ | name of the task to schedule |
Returnsnothing
room_taskSchedule execution of a room task. A room task is used for a room record and is automatically deleted if that corresponding record is deleted. Paramsid | the id to associate with this | task$ | name of the task to schedule | when | centi-seconds until first fire | repeat | repeat in X centi-seconds | group | a numeric group id (currently unused) |
Returnsnothing
clear_room_taskRemove a scheduled room task. Use this to prevent a scheduled task from executing. All tasks scheduled for the given id and name combination will be removed. If id is 0, then all tasks matching the given name will be removed. Paramsid | the id to associate with this | task$ | name of the task to schedule |
Returnsnothing
replica_taskSchedule execution of a replica task. A replica task is used for a replica record and is automatically deleted if that corresponding record is deleted. Paramsid | the id to associate with this | task$ | name of the task to schedule | when | centi-seconds until first fire | repeat | repeat in X centi-seconds | group | a numeric group id (currently unused) |
Returnsnothing
clear_replica_taskRemove a scheduled replica task. Use this to prevent a scheduled task from executing. All tasks scheduled for the given id and name combination will be removed. If id is 0, then all tasks matching the given name will be removed. Paramsid | the id to associate with this | task$ | name of the task to schedule |
Returnsnothing
check_tasksCheck for any pending tasks and run the first one found. This routine is deprecated, and <wait_for_input>() should be used instead. It will check for any pending tasks (pending meaning the time to fire has occurred between the previous call and this call of this routine. Paramsnone Returnsnothing
valid_taskChecks whether a task with the given name has been defined. Paramsname$ | the name of the task |
ReturnsTrue if the task is defined, false otherwise.
dotaskExecutes a task directly. While check_tasks is the preferred method of executing tasks, a mechanism for direct execution is also provided. Once the task completes, control returns to the next statement after the dotask call, just like with regular functions and subroutines. Note that while it is possible to call dotask from another task, doing so will overwrite the game.taskobject value visible to the calling task. Paramsname$ | the name of the task | object | the value that will be available as game.taskobject |
Returnsnothing
game_tasks@Search the list of game tasks. Returns a vector containing information about all scheduled game tasks that match the id and taskname provided. If id is 0, this function will match all game task ids. If task$ is an empty string, this function will match all game task names. Paramsid | search for tasks with this id (use 0 to match all tasks) | task$ | search for tasks with this name (use “” for all tasks) |
ReturnsA vector of strings. Each string in the vector contains the following information about matching tasks: tick time for next task fire, how many ticks until the task will fire, how many ticks between task repeats, id associated with the task, the task group (1 = game, 2 = player, 3 = room, 4 = replica), and the task name.
player_tasks@Search the list of player (node) tasks. Returns a vector containing information about all scheduled player tasks that match the id and taskname provided. If id is 0, this function will match all player task ids. If task$ is an empty string, this function will match all player task names. Paramsid | search for tasks with this id (use 0 to match all tasks) | task$ | search for tasks with this name (use “” for all tasks) |
ReturnsA vector of strings. Each string in the vector contains the following information about matching tasks: tick time for next task fire, how many ticks until the task will fire, how many ticks between task repeats, id associated with the task, the task group (1 = game, 2 = player, 3 = room, 4 = replica), and the task name.
room_tasks@Search the list of room tasks. Returns a vector containing information about all scheduled room tasks that match the id and taskname provided. If id is 0, this function will match all room task ids. If task$ is an empty string, this function will match all room task names. Paramsid | search for tasks with this id (use 0 to match all tasks) | task$ | search for tasks with this name (use “” for all tasks) |
ReturnsA vector of strings. Each string in the vector contains the following information about matching tasks: tick time for next task fire, how many ticks until the task will fire, how many ticks between task repeats, id associated with the task, the task group (1 = game, 2 = player, 3 = room, 4 = replica), and the task name.
replica_tasks@Search the list of replica tasks. Returns a vector containing information about all scheduled replica tasks that match the id and taskname provided. If id is 0, this function will match all replica task ids. If task$ is an empty string, this function will match all replica task names. Paramsid | search for tasks with this id (use 0 to match all tasks) | task$ | search for tasks with this name (use “” for all tasks) |
ReturnsA vector of strings. Each string in the vector contains the following information about matching tasks: tick time for next task fire, how many ticks until the task will fire, how many ticks between task repeats, id associated with the task, the task group (1 = game, 2 = player, 3 = room, 4 = replica), and the task name.
game_task_timeReturns the number of ticks until task fire. This function searches for tasks that match the id and taskname$ provided. If id is 0, this function will match all game task ids. If task$ is an empty string, this function will match all game task names. Paramsid | search for tasks with this id (use 0 to match all tasks) | task$ | search for tasks with this name (use “” for all tasks) |
ReturnsAn integer that indicates the number of ticks until the next task that matches will fire. This function can return a negative number if Rapture has been doing something intensive recently and has not been processing tasks.
player_task_timeReturns the number of ticks until task fire. This function searches for tasks that match the id and taskname$ provided. If id is 0, this function will match all player task ids. If task$ is an empty string, this function will match all player task names. Paramsid | search for tasks with this id (use 0 to match all tasks) | task$ | search for tasks with this name (use “” for all tasks) |
ReturnsAn integer that indicates the number of ticks until the next task that matches will fire. This function can return a negative number if Rapture has been doing something intensive recently and has not been processing tasks.
room_task_timeReturns the number of ticks until task fire. This function searches for tasks that match the id and taskname$ provided. If id is 0, this function will match all room task ids. If task$ is an empty string, this function will match all room task names. Paramsid | search for tasks with this id (use 0 to match all tasks) | task$ | search for tasks with this name (use “” for all tasks) |
ReturnsAn integer that indicates the number of ticks until the next task that matches will fire. This function can return a negative number if Rapture has been doing something intensive recently and has not been processing tasks.
replica_task_timeReturns the number of ticks until task fire. This function searches for tasks that match the id and taskname$ provided. If id is 0, this function will match all replica task ids. If task$ is an empty string, this function will match all replica task names. Paramsid | search for tasks with this id (use 0 to match all tasks) | task$ | search for tasks with this name (use “” for all tasks) |
ReturnsAn integer that indicates the number of ticks until the next task that matches will fire. This function can return a negative number if Rapture has been doing something intensive recently and has not been processing tasks.
|