From edd8c3c664ad005eb32e1968ce80091851ffb817 Mon Sep 17 00:00:00 2001 From: sfan5 Date: Sat, 16 Jan 2021 22:16:04 +0100 Subject: Drop never documented 'alpha' property from nodedef Includes minimal support code for practical reasons. We'll need it for a slightly different purpose next commit. --- games/devtest/mods/testnodes/textures.lua | 15 ++++----------- 1 file changed, 4 insertions(+), 11 deletions(-) (limited to 'games/devtest') diff --git a/games/devtest/mods/testnodes/textures.lua b/games/devtest/mods/testnodes/textures.lua index e0724c229..af3b7f468 100644 --- a/games/devtest/mods/testnodes/textures.lua +++ b/games/devtest/mods/testnodes/textures.lua @@ -51,23 +51,16 @@ for a=1,#alphas do groups = { dig_immediate = 3 }, }) - -- Transparency set via "alpha" parameter + -- Transparency set via texture modifier minetest.register_node("testnodes:alpha_"..alpha, { description = S("Alpha Test Node (@1)", alpha), - -- It seems that only the liquid drawtype supports the alpha parameter - drawtype = "liquid", + drawtype = "glasslike", paramtype = "light", tiles = { - "testnodes_alpha.png", + "testnodes_alpha.png^[opacity:" .. alpha, }, - alpha = alpha, - + use_texture_alpha = true, - liquidtype = "source", - liquid_range = 0, - liquid_viscosity = 0, - liquid_alternative_source = "testnodes:alpha_"..alpha, - liquid_alternative_flowing = "testnodes:alpha_"..alpha, groups = { dig_immediate = 3 }, }) end -- cgit v1.2.3