summaryrefslogtreecommitdiff
path: root/doc/lua_api.txt
diff options
context:
space:
mode:
authorsfan5 <sfan5@live.de>2021-01-17 01:56:50 +0100
committersfan5 <sfan5@live.de>2021-01-29 17:34:41 +0100
commit83229921e5f378625d9ef63ede3dffbe778e1798 (patch)
tree8189436795cad017e2eb858b5d2cc23c16a55f46 /doc/lua_api.txt
parentedd8c3c664ad005eb32e1968ce80091851ffb817 (diff)
downloadminetest-83229921e5f378625d9ef63ede3dffbe778e1798.tar.gz
minetest-83229921e5f378625d9ef63ede3dffbe778e1798.tar.bz2
minetest-83229921e5f378625d9ef63ede3dffbe778e1798.zip
Rework use_texture_alpha to provide three opaque/clip/blend modes
The change that turns nodeboxes and meshes opaque when possible is kept, as is the compatibility code that warns modders to adjust their nodedefs.
Diffstat (limited to 'doc/lua_api.txt')
-rw-r--r--doc/lua_api.txt18
1 files changed, 14 insertions, 4 deletions
diff --git a/doc/lua_api.txt b/doc/lua_api.txt
index cfc150edc..8156f785a 100644
--- a/doc/lua_api.txt
+++ b/doc/lua_api.txt
@@ -4386,6 +4386,8 @@ Utilities
object_step_has_moveresult = true,
-- Whether get_velocity() and add_velocity() can be used on players (5.4.0)
direct_velocity_on_players = true,
+ -- nodedef's use_texture_alpha accepts new string modes (5.4.0)
+ use_texture_alpha_string_modes = true,
}
* `minetest.has_feature(arg)`: returns `boolean, missing_features`
@@ -7340,10 +7342,18 @@ Used by `minetest.register_node`.
-- If the node has a palette, then this setting only has an effect in
-- the inventory and on the wield item.
- use_texture_alpha = false,
- -- Use texture's alpha channel
- -- If this is set to false, the node will be rendered fully opaque
- -- regardless of any texture transparency.
+ use_texture_alpha = ...,
+ -- Specifies how the texture's alpha channel will be used for rendering.
+ -- possible values:
+ -- * "opaque": Node is rendered opaque regardless of alpha channel
+ -- * "clip": A given pixel is either fully see-through or opaque
+ -- depending on the alpha channel being below/above 50% in value
+ -- * "blend": The alpha channel specifies how transparent a given pixel
+ -- of the rendered node is
+ -- The default is "opaque" for drawtypes normal, liquid and flowingliquid;
+ -- "clip" otherwise.
+ -- If set to a boolean value (deprecated): true either sets it to blend
+ -- or clip, false sets it to clip or opaque mode depending on the drawtype.
palette = "palette.png",
-- The node's `param2` is used to select a pixel from the image.