aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorOch Noe <och_noe@forksworld.de>2019-01-19 13:11:13 +0100
committerOch Noe <och_noe@forksworld.de>2019-01-19 13:11:13 +0100
commit71e592ed4060263b15b46acd5f9c5545932395dd (patch)
tree7a6fa14c1c1d3630bf3ff9d880ecee066a748b59
parente3d8aa124d667e958cc092ce324dffb99d691a25 (diff)
downloadmoreblocks-71e592ed4060263b15b46acd5f9c5545932395dd.tar.gz
moreblocks-71e592ed4060263b15b46acd5f9c5545932395dd.tar.bz2
moreblocks-71e592ed4060263b15b46acd5f9c5545932395dd.zip
stained glass now cutable, grval-slopes repaired
-rw-r--r--crafting.lua11
-rw-r--r--nodes.lua160
-rw-r--r--stairsplus/init.lua5
-rw-r--r--stairsplus/registrations.lua9
-rw-r--r--stairsplus/slopes.lua2
5 files changed, 178 insertions, 9 deletions
diff --git a/crafting.lua b/crafting.lua
index 72c5503..875f56a 100644
--- a/crafting.lua
+++ b/crafting.lua
@@ -691,7 +691,7 @@ minetest.register_craft({
minetest.register_craft({
- output = "moreblocks:gravel_slope2_a 12",
+ output = "moreblocks:gravel_slope_2a 12",
recipe = {
{ "","","" },
{ "","","", },
@@ -700,7 +700,7 @@ minetest.register_craft({
})
minetest.register_craft({
- output = "moreblocks:gravel_slope2_b 4",
+ output = "moreblocks:gravel_slope_2b 4",
recipe = {
{ "","","default:gravel", },
{ "","","" },
@@ -709,7 +709,7 @@ minetest.register_craft({
})
minetest.register_craft({
- output = "moreblocks:gravel_slope3_a 18",
+ output = "moreblocks:gravel_slope_3a 18",
recipe = {
{ "","","" },
{ "","","", },
@@ -718,7 +718,7 @@ minetest.register_craft({
})
minetest.register_craft({
- output = "moreblocks:gravel_slope3_b 8",
+ output = "moreblocks:gravel_slope_3b 8",
recipe = {
{ "","","" },
{ "","","default:gravel", },
@@ -727,7 +727,7 @@ minetest.register_craft({
})
minetest.register_craft({
- output = "moreblocks:gravel_slope3_c 8",
+ output = "moreblocks:gravel_slope_3c 8",
recipe = {
{ "","","default:gravel", },
{ "","default:gravel","" },
@@ -736,3 +736,4 @@ minetest.register_craft({
})
+
diff --git a/nodes.lua b/nodes.lua
index 3319dab..24dcbfb 100644
--- a/nodes.lua
+++ b/nodes.lua
@@ -2,6 +2,7 @@
More Blocks: node definitions
Copyright (c) 2011-2017 Hugo Locurcio and contributors.
+ 2018,2019 Och_Noe
Licensed under the zlib license. See LICENSE.md for more information.
--]]
@@ -33,6 +34,57 @@ local box_slope = {
}
}
+local box_slope_half = {
+ type = "fixed",
+ fixed = {
+ {-0.5, -0.5, -0.5, 0.5, -0.375, 0.5},
+ {-0.5, -0.375, -0.25, 0.5, -0.25, 0.5},
+ {-0.5, -0.25, 0, 0.5, -0.125, 0.5},
+ {-0.5, -0.125, 0.25, 0.5, 0, 0.5},
+ }
+}
+
+local box_slope_half_raised = {
+ type = "fixed",
+ fixed = {
+ {-0.5, -0.5, -0.5, 0.5, 0.125, 0.5},
+ {-0.5, 0.125, -0.25, 0.5, 0.25, 0.5},
+ {-0.5, 0.25, 0, 0.5, 0.375, 0.5},
+ {-0.5, 0.375, 0.25, 0.5, 0.5, 0.5},
+ }
+}
+
+
+local box_slope_third = {
+ type = "fixed",
+ fixed = {
+ {-0.5, -0.5, -0.5, 0.5, -0.417 , 0.5},
+ {-0.5, -0.417, -0.25, 0.5, -0.333 , 0.5},
+ {-0.5, -0.333, 0, 0.5, -0.250 , 0.5},
+ {-0.5, -0.250, 0.25, 0.5, -0.167, 0.5},
+ }
+}
+
+local box_slope_third_raised = {
+ type = "fixed",
+ fixed = {
+ {-0.5, -0.5, -0.5, 0.5, -0.083 , 0.5},
+ {-0.5, -0.083, -0.25, 0.5, 0 , 0.5},
+ {-0.5, 0 , 0, 0.5, 0.083 , 0.5},
+ {-0.5, 0.083, 0.25, 0.5, 0.167, 0.5},
+ }
+}
+
+local box_slope_third_top = {
+ type = "fixed",
+ fixed = {
+ {-0.5, -0.5, -0.5, 0.5, 0.250, 0.5},
+ {-0.5, 0.250, -0.25, 0.5, 0.333, 0.5},
+ {-0.5, 0.333, 0, 0.5, 0.417, 0.5},
+ {-0.5, 0.417, 0.25, 0.5, 0.5 , 0.5},
+ }
+}
+
local nodes = {
["wood_tile"] = {
@@ -432,7 +484,7 @@ local nodes = {
one_texture = true,
use_texture_alpha = true,
paramtype = "light",
- no_stairs = true;
+ -- no_stairs = true;
sunlight_propagates = true,
groups = {snappy = 2, cracky = 3, oddly_breakable_by_hand = 3},
sounds = sound_glass,
@@ -537,18 +589,119 @@ local nodes = {
description = S("Gravel Slope"),
tiles = { "default_gravel.png" } ,
no_stairs = true,
- groups = {crumbly = 2, falling_node = 1},
+ groups = {crumbly = 2, falling_node = 1, not_blocking_trains = 1},
sounds = sound_gravel,
drawtype = "mesh",
mesh = "moreblocks_slope.obj",
collision_box = box_slope,
selection_box = box_slope,
+ sunlight_propagates = false,
+ light_source = 0,
+ paramtype = "light",
paramtype2 = "facedir", -- neu
on_rotate = screwdriver.rotate_simple , -- neu
is_ground_content = false, --neu
- buildable_to = true;
+ -- buildable_to = true;
},
+ ["gravel_slope_2a"] = {
+ description = S("Gravel Slope 2a"),
+ tiles = { "default_gravel.png" } ,
+ no_stairs = true,
+ groups = {crumbly = 2, falling_node = 1, not_blocking_trains = 1},
+ sounds = sound_gravel,
+ drawtype = "mesh",
+ mesh = "moreblocks_slope_half.obj",
+ collision_box = box_slope_half,
+ selection_box = box_slope_half,
+ sunlight_propagates = false,
+ light_source = 0,
+ paramtype = "light",
+ paramtype2 = "facedir", -- neu
+ on_rotate = screwdriver.rotate_simple , -- neu
+ is_ground_content = false, --neu
+ -- buildable_to = true;
+ },
+
+ ["gravel_slope_2b"] = {
+ description = S("Gravel Slope 2b"),
+ tiles = { "default_gravel.png" } ,
+ no_stairs = true,
+ groups = {crumbly = 2, falling_node = 1, not_blocking_trains = 1},
+ sounds = sound_gravel,
+ drawtype = "mesh",
+ mesh = "moreblocks_slope_half_raised.obj",
+ collision_box = box_slope_half_raised,
+ selection_box = box_slope_half_raised,
+ sunlight_propagates = false,
+ light_source = 0,
+ paramtype = "light",
+ paramtype2 = "facedir", -- neu
+ on_rotate = screwdriver.rotate_simple , -- neu
+ is_ground_content = false, --neu
+ -- buildable_to = true;
+ },
+
+
+ ["gravel_slope_3a"] = {
+ description = S("Gravel Slope 3a"),
+ tiles = { "default_gravel.png" } ,
+ no_stairs = true,
+ groups = {crumbly = 2, falling_node = 1, not_blocking_trains = 1},
+ sounds = sound_gravel,
+ drawtype = "mesh",
+ mesh = "moreblocks_slope_third.obj",
+ collision_box = box_slope_third,
+ selection_box = box_slope_third,
+ sunlight_propagates = false,
+ light_source = 0,
+ paramtype = "light",
+ paramtype2 = "facedir", -- neu
+ on_rotate = screwdriver.rotate_simple , -- neu
+ is_ground_content = false, --neu
+ -- buildable_to = true;
+ },
+
+ ["gravel_slope_3b"] = {
+ description = S("Gravel Slope 3b"),
+ tiles = { "default_gravel.png" } ,
+ no_stairs = true,
+ groups = {crumbly = 2, falling_node = 1, not_blocking_trains = 1},
+ sounds = sound_gravel,
+ drawtype = "mesh",
+ mesh = "moreblocks_slope_third_raised.obj",
+ collision_box = box_slope_third_raised,
+ selection_box = box_slope_third_raised,
+ sunlight_propagates = false,
+ light_source = 0,
+ paramtype = "light",
+ paramtype2 = "facedir", -- neu
+ on_rotate = screwdriver.rotate_simple , -- neu
+ is_ground_content = false, --neu
+ -- buildable_to = true;
+ },
+
+ ["gravel_slope_3c"] = {
+ description = S("Gravel Slope 3c"),
+ tiles = { "default_gravel.png" } ,
+ no_stairs = true,
+ groups = {crumbly = 2, falling_node = 1, not_blocking_trains = 1},
+ sounds = sound_gravel,
+ drawtype = "mesh",
+ mesh = "moreblocks_slope_third_top.obj",
+ collision_box = box_slope_third_top,
+ selection_box = box_slope_third_top,
+ sunlight_propagates = false,
+ light_source = 0,
+ paramtype = "light",
+ paramtype2 = "facedir", -- neu
+ on_rotate = screwdriver.rotate_simple , -- neu
+ is_ground_content = false, --neu
+ -- buildable_to = true;
+ },
+
+
+
}
if minetest.get_modpath("ethereal") then
@@ -580,6 +733,7 @@ for name, def in pairs(nodes) do
sunlight_propagates = def.sunlight_propagates,
light_source = def.light_source,
sounds = def.sounds,
+ use_texture_alpha = def.use_texture_alpha
})
end
end
diff --git a/stairsplus/init.lua b/stairsplus/init.lua
index 5cd415c..880349a 100644
--- a/stairsplus/init.lua
+++ b/stairsplus/init.lua
@@ -91,3 +91,8 @@ dofile(modpath .. "/slopes.lua")
dofile(modpath .. "/panels.lua")
dofile(modpath .. "/microblocks.lua")
dofile(modpath .. "/registrations.lua")
+
+
+
+
+
diff --git a/stairsplus/registrations.lua b/stairsplus/registrations.lua
index 694fb68..413ecca 100644
--- a/stairsplus/registrations.lua
+++ b/stairsplus/registrations.lua
@@ -85,7 +85,9 @@ for _, name in pairs(default_nodes) do
sounds = ndef.sounds,
tiles = tiles,
sunlight_propagates = true,
- light_source = ndef.light_source
+ light_source = ndef.light_source,
+ use_texture_alpha = ndef.use_texture_alpha
+
})
end
end
@@ -126,3 +128,8 @@ if minetest.get_modpath("wool") then
})
end
end
+
+
+
+
+
diff --git a/stairsplus/slopes.lua b/stairsplus/slopes.lua
index 7d18b3d..6d934f6 100644
--- a/stairsplus/slopes.lua
+++ b/stairsplus/slopes.lua
@@ -120,6 +120,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
})
end
@@ -249,6 +250,7 @@ function stairsplus:register_slope(modname, subname, recipeitem, fields)
def.paramtype2 = def.paramtype2 or "facedir"
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 fields.drop and not (type(fields.drop) == "table") then
def.drop = modname.. ":slope_" ..fields.drop..alternate