summaryrefslogtreecommitdiff
path: root/doc/lua_api.txt
diff options
context:
space:
mode:
authorLuke Puchner-Hardman <x.lukk3.x@gmail.com>2014-09-23 14:39:34 +0200
committersfan5 <sfan5@live.de>2017-01-02 15:28:06 +0100
commit7057c196c442ff3484b53f48d940f4c9e0ffe23a (patch)
treeea6e57d1755253577e3eda6fe22280314d22fb87 /doc/lua_api.txt
parent523f0e8c5bce0cb58215dc1f9d027cf32394e3c3 (diff)
downloadminetest-7057c196c442ff3484b53f48d940f4c9e0ffe23a.tar.gz
minetest-7057c196c442ff3484b53f48d940f4c9e0ffe23a.tar.bz2
minetest-7057c196c442ff3484b53f48d940f4c9e0ffe23a.zip
Added "[sheet" to the texture special commands.
"[sheet:WxH:X,Y" assumes the base image is a tilesheet with W*H tiles on it and crops to the tile at position X,Y. Basically it works like "[verticalframe" but in 2D. For testing, I combined the four default_chest images into one.
Diffstat (limited to 'doc/lua_api.txt')
-rw-r--r--doc/lua_api.txt5
1 files changed, 5 insertions, 0 deletions
diff --git a/doc/lua_api.txt b/doc/lua_api.txt
index d2ddc635b..648a29303 100644
--- a/doc/lua_api.txt
+++ b/doc/lua_api.txt
@@ -403,6 +403,11 @@ Apply a mask to the base image.
The mask is applied using binary AND.
+#### `[sheet:<w>x<h>:<x>,<y>`
+Retrieves a tile at position x,y from the base image
+which it assumes to be a tilesheet with dimensions w,h.
+
+
#### `[colorize:<color>:<ratio>`
Colorize the textures with the given color.
`<color>` is specified as a `ColorString`.