Delay (MPI)
From Tapestries MUCK
(Difference between revisions)
Line 1: | Line 1: | ||
[[Category:MPI functions]] | [[Category:MPI functions]] | ||
- | + | =delay= | |
<mpi>{delay:secs,expr}</mpi> | <mpi>{delay:secs,expr}</mpi> | ||
Evaluates the given expression, then puts the result of that on the timequeue, to execute after the given number of seconds. At that time, the string is evaluated again, and displayed to the user, or to the room, depending on whether it was run from a regular message such as @succ, or from an omessage such as @osucc. | Evaluates the given expression, then puts the result of that on the timequeue, to execute after the given number of seconds. At that time, the string is evaluated again, and displayed to the user, or to the room, depending on whether it was run from a regular message such as @succ, or from an omessage such as @osucc. |
Revision as of 08:03, 30 March 2007
delay
{delay:secs,expr}
Evaluates the given expression, then puts the result of that on the timequeue, to execute after the given number of seconds. At that time, the string is evaluated again, and displayed to the user, or to the room, depending on whether it was run from a regular message such as @succ, or from an omessage such as @osucc.
Since the expression is evaluated both before and after being delayed, you need to put MPI code that is to run after the delay within a {lit:expr} command. If a {delay} evaluation is a null string, then the notify or notify_except will not be done.
{delay} will return the process ID of the event it puts on the timequeue.