Skip to content

Commit

Permalink
Lua_api.txt: Document inventory sending behaviour (#7720)
Browse files Browse the repository at this point in the history
  • Loading branch information
zeuner authored and paramat committed Dec 18, 2018
1 parent e7367f0 commit 7a4d4bc
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions doc/lua_api.txt
Expand Up @@ -1800,6 +1800,9 @@ examples.
Position and size units are inventory slots, `X` and `Y` position the formspec
element relative to the top left of the menu or container. `W` and `H` are its
width and height values.
Inventories with a `player:<name>` inventory location are only sent to the
player named `<name>`.

When displaying text which can contain formspec code, e.g. text set by a player,
use `minetest.formspec_escape`.
For coloured text you can use `minetest.colorize`.
Expand Down Expand Up @@ -1885,11 +1888,13 @@ Elements

### `list[<inventory location>;<list name>;<X>,<Y>;<W>,<H>;]`

* Show an inventory list
* Show an inventory list if it has been sent to the client. Nothing will
be shown if the inventory list is of size 0.

### `list[<inventory location>;<list name>;<X>,<Y>;<W>,<H>;<starting item index>]`

* Show an inventory list
* Show an inventory list if it has been sent to the client. Nothing will
be shown if the inventory list is of size 0.

### `listring[<inventory location>;<list name>]`

Expand Down

0 comments on commit 7a4d4bc

Please sign in to comment.