diff options
| author | Alexander Gavrilov | 2012-05-16 17:06:08 +0400 |
|---|---|---|
| committer | Alexander Gavrilov | 2012-05-16 17:06:08 +0400 |
| commit | dbd39af58a1eea630b6e390375517acb79b179f2 (patch) | |
| tree | 23b3137f624be5d741e3b831bc662c0e9e88a0a3 /Lua API.html | |
| parent | e77c9dc730fdd94423319b744fb4162bd36e8377 (diff) | |
| download | dfhack-dbd39af58a1eea630b6e390375517acb79b179f2.tar.gz dfhack-dbd39af58a1eea630b6e390375517acb79b179f2.tar.bz2 dfhack-dbd39af58a1eea630b6e390375517acb79b179f2.tar.xz | |
Support testing and modifying pending timeout callbacks.
Diffstat (limited to 'Lua API.html')
| -rw-r--r-- | Lua API.html | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/Lua API.html b/Lua API.html index ed2e9f6a..d44d82ba 100644 --- a/Lua API.html +++ b/Lua API.html @@ -1265,6 +1265,12 @@ and cannot be queued until it is loaded again. Returns the timer id, or <em>nil</em> if unsuccessful due to world being unloaded.</p> </li> +<li><p class="first"><tt class="docutils literal"><span class="pre">dfhack.timeout_active(id[,new_callback])</span></tt></p> +<p>Returns the active callback with the given id, or <em>nil</em> +if inactive or nil id. If called with 2 arguments, replaces +the current callback with the given value, if still active. +Using <tt class="docutils literal">timeout_active(id,nil)</tt> cancels the timer.</p> +</li> <li><p class="first"><tt class="docutils literal">dfhack.onStateChange.foo = function(code)</tt></p> <p>Event. Receives the same codes as plugin_onstatechange in C++.</p> </li> |
