diff options
author | Och Noe <och_noe@forksworld.de> | 2024-09-20 00:50:48 +0200 |
---|---|---|
committer | Och Noe <och_noe@forksworld.de> | 2024-09-20 00:50:48 +0200 |
commit | eff07d2e0c93dcefe4a7170b3939b6a9a172d462 (patch) | |
tree | 71109fc6a50ffdf0edfdd3ebefdca530c4ce9d1f /stairsplus | |
parent | eeb4f5cf3ca2742a4ebf94ae8d5b8b3c68245a9e (diff) | |
download | moreblocks-eff07d2e0c93dcefe4a7170b3939b6a9a172d462.tar.gz moreblocks-eff07d2e0c93dcefe4a7170b3939b6a9a172d462.tar.bz2 moreblocks-eff07d2e0c93dcefe4a7170b3939b6a9a172d462.zip |
texture transparency patches, made by erstazi THANKS
Diffstat (limited to 'stairsplus')
-rw-r--r-- | stairsplus/microblocks.lua | 2 | ||||
-rw-r--r-- | stairsplus/panels.lua | 2 | ||||
-rw-r--r-- | stairsplus/slabs.lua | 2 | ||||
-rw-r--r-- | stairsplus/slopes.lua | 6 | ||||
-rw-r--r-- | stairsplus/stairs.lua | 2 |
5 files changed, 12 insertions, 2 deletions
diff --git a/stairsplus/microblocks.lua b/stairsplus/microblocks.lua index 49e4dcd..f65eb60 100644 --- a/stairsplus/microblocks.lua +++ b/stairsplus/microblocks.lua @@ -86,6 +86,7 @@ end function stairsplus:register_micro(modname, subname, recipeitem, fields) local defs = stairsplus.copytable(microblocks_defs) local desc = S("%s Microblock"):format(fields.description) + local use_texture_alpha = minetest.features.use_texture_alpha_string_modes and "blend" or fields.use_texture_alpha for alternate, def in pairs(defs) do for k, v in pairs(fields) do def[k] = v @@ -93,6 +94,7 @@ function stairsplus:register_micro(modname, subname, recipeitem, fields) def.drawtype = "nodebox" def.paramtype = "light" def.paramtype2 = def.paramtype2 or "facedir" + def.use_texture_alpha = use_texture_alpha def.on_place = minetest.rotate_node def.groups = stairsplus:prepare_groups(fields.groups) if alternate == "_1" then diff --git a/stairsplus/panels.lua b/stairsplus/panels.lua index 82a7300..4ffd8ca 100644 --- a/stairsplus/panels.lua +++ b/stairsplus/panels.lua @@ -86,6 +86,7 @@ end function stairsplus:register_panel(modname, subname, recipeitem, fields) local defs = stairsplus.copytable(panels_defs) local desc = S("%s Panel"):format(fields.description) + local use_texture_alpha = minetest.features.use_texture_alpha_string_modes and "blend" or fields.use_texture_alpha for alternate, def in pairs(defs) do for k, v in pairs(fields) do def[k] = v @@ -93,6 +94,7 @@ function stairsplus:register_panel(modname, subname, recipeitem, fields) def.drawtype = "nodebox" def.paramtype = "light" def.paramtype2 = def.paramtype2 or "facedir" + def.use_texture_alpha = use_texture_alpha def.on_place = minetest.rotate_node def.description = desc def.groups = stairsplus:prepare_groups(fields.groups) diff --git a/stairsplus/slabs.lua b/stairsplus/slabs.lua index 3af7d7e..18a25a7 100644 --- a/stairsplus/slabs.lua +++ b/stairsplus/slabs.lua @@ -65,6 +65,7 @@ end function stairsplus:register_slab(modname, subname, recipeitem, fields) local defs = stairsplus.copytable(slabs_defs) local desc_base = S("%s Slab"):format(fields.description) + local use_texture_alpha = minetest.features.use_texture_alpha_string_modes and "blend" or fields.use_texture_alpha for alternate, shape in pairs(defs) do local def = {} @@ -94,6 +95,7 @@ function stairsplus:register_slab(modname, subname, recipeitem, fields) def.drawtype = "nodebox" def.paramtype = "light" def.paramtype2 = def.paramtype2 or "facedir" + def.use_texture_alpha = use_texture_alpha def.on_place = minetest.rotate_node def.groups = stairsplus:prepare_groups(fields.groups) if alternate == "_1" or alternate == "_two_sides" then diff --git a/stairsplus/slopes.lua b/stairsplus/slopes.lua index 91a78f2..9f16730 100644 --- a/stairsplus/slopes.lua +++ b/stairsplus/slopes.lua @@ -113,6 +113,7 @@ local box_slope_outer_half_raised = { -- Node will be called <modname>:slope_<subname> function register_slope(modname, subname, recipeitem, groups, images, description, drop, light) + local use_texture_alpha = minetest.features.use_texture_alpha_string_modes and "blend" or true stairsplus:register_slope(modname, subname, recipeitem, { groups = groups, tiles = images, @@ -120,7 +121,7 @@ function register_slope(modname, subname, recipeitem, groups, images, descriptio drop = drop, light_source = light, sounds = default.node_sound_stone_defaults(), - use_texture_alpha = use_texture_alpha + use_texture_alpha = use_texture_alpha }) end @@ -241,6 +242,7 @@ end function stairsplus:register_slope(modname, subname, recipeitem, fields) local defs = stairsplus.copytable(slopes_defs) local desc = S("%s Slope"):format(fields.description) + local use_texture_alpha = minetest.features.use_texture_alpha_string_modes and "blend" or fields.use_texture_alpha for alternate, def in pairs(defs) do for k, v in pairs(fields) do def[k] = v @@ -248,9 +250,9 @@ function stairsplus:register_slope(modname, subname, recipeitem, fields) def.drawtype = "mesh" def.paramtype = "light" def.paramtype2 = def.paramtype2 or "facedir" + def.use_texture_alpha = use_texture_alpha def.on_place = minetest.rotate_node def.description = desc - def.use_texture_alpha = fields.use_texture_alpha def.groups = stairsplus:prepare_groups(fields.groups) if alternate == "_half" or alternate == "_half_raised" then def.groups.not_blocking_trains = 1 diff --git a/stairsplus/stairs.lua b/stairsplus/stairs.lua index 0291e7d..55ee51e 100644 --- a/stairsplus/stairs.lua +++ b/stairsplus/stairs.lua @@ -126,6 +126,7 @@ end function stairsplus:register_stair(modname, subname, recipeitem, fields) local defs = stairsplus.copytable(stairs_defs) local desc = S("%s Stairs"):format(fields.description) + local use_texture_alpha = minetest.features.use_texture_alpha_string_modes and "blend" or fields.use_texture_alpha for alternate, def in pairs(defs) do for k, v in pairs(fields) do def[k] = v @@ -133,6 +134,7 @@ function stairsplus:register_stair(modname, subname, recipeitem, fields) def.drawtype = "nodebox" def.paramtype = "light" def.paramtype2 = def.paramtype2 or "facedir" + def.use_texture_alpha = use_texture_alpha def.on_place = minetest.rotate_node def.description = desc def.groups = stairsplus:prepare_groups(fields.groups) |