summaryrefslogtreecommitdiff
path: root/server/libs/lua/coroutine.lni
diff options
context:
space:
mode:
Diffstat (limited to 'server/libs/lua/coroutine.lni')
-rw-r--r--server/libs/lua/coroutine.lni90
1 files changed, 90 insertions, 0 deletions
diff --git a/server/libs/lua/coroutine.lni b/server/libs/lua/coroutine.lni
new file mode 100644
index 00000000..51b717b9
--- /dev/null
+++ b/server/libs/lua/coroutine.lni
@@ -0,0 +1,90 @@
+[coroutine]
+type = 'table'
+[[.source]]
+type = 'global'
+``````````
+type = 'library'
+name = 'coroutine'
+
+<default>
+type = 'function'
+parent = {
+ 1 = {
+ type = 'global',
+ name = 'coroutine',
+ },
+ 2 = {
+ type = 'library',
+ name = 'coroutine',
+ }
+}
+
+[create]
+[[.args]]
+name = 'f'
+type = 'function'
+[[.returns]]
+name = 'coroutine'
+type = 'thread'
+
+[isyieldable]
+[[.returns]]
+type = 'boolean'
+
+[resume]
+[[.args]]
+name = 'co'
+type = 'thread'
+``````````
+name = 'val1'
+optional = 'after'
+``````````
+type = '...'
+[[.returns]]
+name = 'success'
+type = 'boolean'
+``````````
+name = 'result'
+``````````
+type = '...'
+
+[running]
+[[.returns]]
+name = 'running_co'
+type = 'thread'
+``````````
+name = 'is_main'
+type = 'boolean'
+
+[status]
+[[.args]]
+name = 'co'
+type = 'thread'
+[[.returns]]
+name = 'status'
+type = 'string'
+[[.enums]]
+name = 'status'
+enum = 'running'
+``````````
+name = 'status'
+enum = 'suspended'
+``````````
+name = 'status'
+enum = 'normal'
+``````````
+name = 'status'
+enum = 'dead'
+
+[wrap]
+[[.args]]
+name = 'f'
+type = 'function'
+[[.returns]]
+type = '...'
+
+[yield]
+[[.args]]
+type = '...'
+[[.returns]]
+type = '...'