summaryrefslogtreecommitdiff
path: root/src/nodedef.h
diff options
context:
space:
mode:
authorparamat <mat.gregory@virginmedia.com>2017-03-29 03:40:30 +0100
committerparamat <mat.gregory@virginmedia.com>2017-03-30 04:52:54 +0100
commitea549bbae3650d246db7b70a2b07485a4b404409 (patch)
tree0f70b68d6f5f26c83050549562d1077418dd72b0 /src/nodedef.h
parentfbc1432fe8e821f58e97a5f35340efb2f46f93e4 (diff)
downloadminetest-ea549bbae3650d246db7b70a2b07485a4b404409.tar.gz
minetest-ea549bbae3650d246db7b70a2b07485a4b404409.tar.bz2
minetest-ea549bbae3650d246db7b70a2b07485a4b404409.zip
Paramtype2: Add missing type CPT2_GLASSLIKE_LIQUID_LEVEL
Add the missing paramtype2 for param2 controlling the liquid level inside the glasslike_framed drawtype. Add missing documentation of the feature to lua_api.txt. Update and improve comments for drawtype enumerations in nodedef.h.
Diffstat (limited to 'src/nodedef.h')
-rw-r--r--src/nodedef.h52
1 files changed, 37 insertions, 15 deletions
diff --git a/src/nodedef.h b/src/nodedef.h
index 4a9908ecc..da3345d80 100644
--- a/src/nodedef.h
+++ b/src/nodedef.h
@@ -74,7 +74,9 @@ enum ContentParamType2
// 3 bits of palette index, then facedir
CPT2_COLORED_FACEDIR,
// 5 bits of palette index, then wallmounted
- CPT2_COLORED_WALLMOUNTED
+ CPT2_COLORED_WALLMOUNTED,
+ // Glasslike framed drawtype internal liquid level, param2 values 0 to 63
+ CPT2_GLASSLIKE_LIQUID_LEVEL,
};
enum LiquidType
@@ -144,26 +146,46 @@ public:
enum NodeDrawType
{
- NDT_NORMAL, // A basic solid block
- NDT_AIRLIKE, // Nothing is drawn
- NDT_LIQUID, // Do not draw face towards same kind of flowing/source liquid
- NDT_FLOWINGLIQUID, // A very special kind of thing
- NDT_GLASSLIKE, // Glass-like, don't draw faces towards other glass
- NDT_ALLFACES, // Leaves-like, draw all faces no matter what
- NDT_ALLFACES_OPTIONAL, // Fancy -> allfaces, fast -> normal
+ // A basic solid block
+ NDT_NORMAL,
+ // Nothing is drawn
+ NDT_AIRLIKE,
+ // Do not draw face towards same kind of flowing/source liquid
+ NDT_LIQUID,
+ // A very special kind of thing
+ NDT_FLOWINGLIQUID,
+ // Glass-like, don't draw faces towards other glass
+ NDT_GLASSLIKE,
+ // Leaves-like, draw all faces no matter what
+ NDT_ALLFACES,
+ // Enabled -> ndt_allfaces, disabled -> ndt_normal
+ NDT_ALLFACES_OPTIONAL,
+ // Single plane perpendicular to a surface
NDT_TORCHLIKE,
+ // Single plane parallel to a surface
NDT_SIGNLIKE,
+ // 2 vertical planes in a 'X' shape diagonal to XZ axes.
+ // paramtype2 = "meshoptions" allows various forms, sizes and
+ // vertical and horizontal random offsets.
NDT_PLANTLIKE,
+ // Fenceposts that connect to neighbouring fenceposts with horizontal bars
NDT_FENCELIKE,
+ // Selects appropriate junction texture to connect like rails to
+ // neighbouring raillikes.
NDT_RAILLIKE,
+ // Custom Lua-definable structure of multiple cuboids
NDT_NODEBOX,
- NDT_GLASSLIKE_FRAMED, // Glass-like, draw connected frames and all all
- // visible faces
- // uses 2 textures, one for frames, second for faces
- NDT_FIRELIKE, // Draw faces slightly rotated and only on connecting nodes,
- NDT_GLASSLIKE_FRAMED_OPTIONAL, // enabled -> connected, disabled -> Glass-like
- // uses 2 textures, one for frames, second for faces
- NDT_MESH, // Uses static meshes
+ // Glass-like, draw connected frames and all visible faces.
+ // param2 > 0 defines 64 levels of internal liquid
+ // Uses 3 textures, one for frames, second for faces,
+ // optional third is a 'special tile' for the liquid.
+ NDT_GLASSLIKE_FRAMED,
+ // Draw faces slightly rotated and only on neighbouring nodes
+ NDT_FIRELIKE,
+ // Enabled -> ndt_glasslike_framed, disabled -> ndt_glasslike
+ NDT_GLASSLIKE_FRAMED_OPTIONAL,
+ // Uses static meshes
+ NDT_MESH,
};
// Mesh options for NDT_PLANTLIKE with CPT2_MESHOPTIONS