summaryrefslogtreecommitdiff
path: root/doc
diff options
context:
space:
mode:
authorDS <vorunbekannt75@web.de>2022-02-10 12:17:52 +0100
committerGitHub <noreply@github.com>2022-02-10 06:17:52 -0500
commita8707158a5be8c604fdb028a9c5f68ce5804016e (patch)
treede95d4fccfccf81c3f1dd3cce8f7146f947c1208 /doc
parentad1da994b2b9d660c41f8ba784ff830aa2693d3b (diff)
downloadminetest-a8707158a5be8c604fdb028a9c5f68ce5804016e.tar.gz
minetest-a8707158a5be8c604fdb028a9c5f68ce5804016e.tar.bz2
minetest-a8707158a5be8c604fdb028a9c5f68ce5804016e.zip
Allow to set the displayed item count and its alignment via meta (#8448)
* Allow to set the displayed item count and its offset via meta * fix rect constr call * devtest: add dump_item chatcommand * fix rect2 constr call (sdim is a position (typedef for v2s32), not a dimension) and remove background because it would work now * add missing utf8 to wide conversion * rename to count_meta
Diffstat (limited to 'doc')
-rw-r--r--doc/lua_api.txt7
1 files changed, 7 insertions, 0 deletions
diff --git a/doc/lua_api.txt b/doc/lua_api.txt
index 7061a5b8a..1dc5f305d 100644
--- a/doc/lua_api.txt
+++ b/doc/lua_api.txt
@@ -2174,6 +2174,13 @@ Some of the values in the key-value store are handled specially:
* `color`: A `ColorString`, which sets the stack's color.
* `palette_index`: If the item has a palette, this is used to get the
current color from the palette.
+* `count_meta`: Replace the displayed count with any string.
+* `count_alignment`: Set the alignment of the displayed count value. This is an
+ int value. The lowest 2 bits specify the alignment in x-direction, the 3rd and
+ 4th bit specify the alignment in y-direction:
+ 0 = default, 1 = left / up, 2 = middle, 3 = right / down
+ The default currently is the same as right/down.
+ Example: 6 = 2 + 1*4 = middle,up
Example: