summaryrefslogtreecommitdiff
path: root/src/emap/script_buildins.c
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2016-08-17 02:05:49 +0300
committerAndrei Karas <akaras@inbox.ru>2016-08-17 02:05:49 +0300
commitf63584457f44a32e7e62587ac4802a6d31bb8408 (patch)
tree32d63bfc506c27424cb9d912d7caef59ef9315ed /src/emap/script_buildins.c
parent30fc330b4b7fcdca0328744055f82def2a3a7c0f (diff)
downloadplugin-f63584457f44a32e7e62587ac4802a6d31bb8408.tar.gz
plugin-f63584457f44a32e7e62587ac4802a6d31bb8408.tar.bz2
plugin-f63584457f44a32e7e62587ac4802a6d31bb8408.tar.xz
plugin-f63584457f44a32e7e62587ac4802a6d31bb8408.zip
Add function for convert label to int and int to label.
New functions: getlabel - get label and return int tolabel - get int and return label
Diffstat (limited to 'src/emap/script_buildins.c')
-rw-r--r--src/emap/script_buildins.c12
1 files changed, 12 insertions, 0 deletions
diff --git a/src/emap/script_buildins.c b/src/emap/script_buildins.c
index 3c7dbc3..2ada5ca 100644
--- a/src/emap/script_buildins.c
+++ b/src/emap/script_buildins.c
@@ -2088,3 +2088,15 @@ BUILDIN(htiDelete)
}
#undef checkHtIteratorExists
+
+BUILDIN(getLabel)
+{
+ script_pushint(st, script_getnum(st, 2));
+ return true;
+}
+
+BUILDIN(toLabel)
+{
+ script_pushlabel(st, script_getnum(st, 2));
+ return true;
+}