diff options
author | Perttu Ahola <celeron55@gmail.com> | 2012-06-06 00:15:33 +0300 |
---|---|---|
committer | Perttu Ahola <celeron55@gmail.com> | 2012-06-06 00:15:33 +0300 |
commit | 430d6e1cca2c970aa6b78194526ce3c28cca8656 (patch) | |
tree | 321dbb5e9c9d5085024b0e63effe932c6d8b79a7 /doc | |
parent | 3a0562bebcb91d05fceb5a1f9ded539f77a625e4 (diff) | |
download | minetest-430d6e1cca2c970aa6b78194526ce3c28cca8656.tar.gz minetest-430d6e1cca2c970aa6b78194526ce3c28cca8656.tar.bz2 minetest-430d6e1cca2c970aa6b78194526ce3c28cca8656.zip |
Fix small errors in lua_api.txt
Diffstat (limited to 'doc')
-rw-r--r-- | doc/lua_api.txt | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/doc/lua_api.txt b/doc/lua_api.txt index e6e24b90a..5ec8ef79b 100644 --- a/doc/lua_api.txt +++ b/doc/lua_api.txt @@ -569,7 +569,7 @@ Example stuff: local meta = minetest.env:get_meta(pos) meta:set_string("formspec", "invsize[8,9;]".. - "list[current_name;main;0,0;8,4;]".. + "list[context;main;0,0;8,4;]".. "list[current_player;main;0,5;8,4;]") meta:set_string("infotext", "Chest"); local inv = meta:get_inventory() @@ -580,7 +580,7 @@ meta:from_table({ main = {[1] = "default:dirt", [2] = "", [3] = "", [4] = "", [5] = "", [6] = "", [7] = "", [8] = "", [9] = "", [10] = "", [11] = "", [12] = "", [13] = "", [14] = "default:cobble", [15] = "", [16] = "", [17] = "", [18] = "", [19] = "", [20] = "default:cobble", [21] = "", [22] = "", [23] = "", [24] = "", [25] = "", [26] = "", [27] = "", [28] = "", [29] = "", [30] = "", [31] = "", [32] = ""} }, fields = { - formspec = "invsize[8,9;]list[current_name;main;0,0;8,4;]list[current_player;main;0,5;8,4;]", + formspec = "invsize[8,9;]list[context;main;0,0;8,4;]list[current_player;main;0,5;8,4;]", infotext = "Chest" } }) @@ -596,13 +596,13 @@ examples. Examples: - Chest: invsize[8,9;] - list[current_name;main;0,0;8,4;] + list[context;main;0,0;8,4;] list[current_player;main;0,5;8,4;] - Furnace: invsize[8,9;] - list[current_name;fuel;2,3;1,1;] - list[current_name;src;2,1;1,1;] - list[current_name;dst;5,1;2,2;] + list[context;fuel;2,3;1,1;] + list[context;src;2,1;1,1;] + list[context;dst;5,1;2,2;] list[current_player;main;0,5;8,4;] - Minecraft-like player inventory invsize[8,7.5;] @@ -861,7 +861,7 @@ methods: - add_entity(pos, name): Spawn Lua-defined entity at position ^ Returns ObjectRef, or nil if failed -- add_item(pos, itemstring): Spawn item +- add_item(pos, item): Spawn item ^ Returns ObjectRef, or nil if failed - get_meta(pos) -- Get a NodeMetaRef at that position - get_player_by_name(name) -- Get an ObjectRef to a player |