-- =================================================================== local cvt = default.convert_node local dont_reduce_node_count = default.dont_reduce_node_count local nodepart local neednode local fromnode local targetmod local baselist local modlist -- =================================================================== targetmod = "darkage" baselist = { "basalt_rubble", "marble_tile" } for k,nodepart in pairs (baselist) do neednode = targetmod .. ":slope_" .. nodepart fromnode = targetmod .. ":" .. nodepart local desc = string.gsub (nodepart, "_", " ") if dont_reduce_node_count and coderblocks.has_moreblocks and minetest.registered_nodes [neednode] == nil and minetest.registered_nodes [fromnode] ~= nil then local img = targetmod .. "_" .. nodepart .. ".png" stairsplus:register_all (targetmod, nodepart, fromnode, { description = desc , groups = { cracky=2, stone=1 } , tiles = { img } , }) end end cvt ("darkage:slab_marble_tile_1" , "darkage:slab_marble_tile" ) -- =================================================================== targetmod = "technic" baselist = { "carbon_steel_block" , "marble_bricks" , "stainless_steel_block" , } for k,nodepart in pairs (baselist) do neednode = targetmod .. ":slope_" .. nodepart fromnode = targetmod .. ":" .. nodepart if dont_reduce_node_count and coderblocks.has_moreblocks and minetest.registered_nodes [neednode] == nil and minetest.registered_nodes [fromnode] ~= nil then local img = targetmod .. "_" .. nodepart .. ".png" stairsplus:register_all (targetmod, nodepart, fromnode, { groups = { cracky=3, not_in_creative_inventory=1 } , description = nodepart , tiles = { img } , }) end end -- =================================================================== cvt ("stairs:slope_quartz_block" , "stairs:slope_quartzblock" ) targetmod = "quartz" baselist = { "block" } for k,nodepart in pairs (baselist) do neednode = targetmod .. ":slope_" .. nodepart fromnode = targetmod .. ":" .. nodepart if coderblocks.has_moreblocks and minetest.registered_nodes [neednode] == nil and minetest.registered_nodes [fromnode] ~= nil then local img = targetmod .. "_" .. nodepart .. ".png" stairsplus:register_all (targetmod, nodepart, fromnode, { groups = { cracky=2, not_in_creative_inventory=1 } , description = nodepart , tiles = { img } , }) end end -- =================================================================== targetmod = "prefab" baselist = { "concrete_block" } for k,nodepart in pairs (baselist) do neednode = targetmod .. ":slope_" .. nodepart fromnode = targetmod .. ":" .. nodepart if dont_reduce_node_count and coderblocks.has_moreblocks and minetest.registered_nodes [neednode] == nil and minetest.registered_nodes [fromnode] ~= nil then local img = targetmod .. "_" .. nodepart .. ".png" stairsplus:register_all (targetmod, nodepart, fromnode, { groups = { cracky=2, not_in_creative_inventory=1 } , description = nodepart , tiles = { img } , }) end end -- =================================================================== modlist = { "basic_materials", "gloopblocks" } for k_mod, v_mod in pairs (modlist) do targetmod = v_mod baselist = { "cement", "cement_block" } for k,nodepart in pairs (baselist) do neednode = targetmod .. ":slope_" .. nodepart fromnode = targetmod .. ":" .. nodepart if coderblocks.has_moreblocks and minetest.registered_nodes [neednode] == nil and minetest.registered_nodes [fromnode] ~= nil then local img = targetmod .. "_" .. nodepart .. ".png" stairsplus:register_all (targetmod, nodepart, fromnode, { groups = { cracky=2, not_in_creative_inventory=1 } , description = nodepart , tiles = { img } , }) end end end -- =================================================================== nodepart = "circlestonebrick" neednode = "stairs:stair_" .. nodepart fromnode = "moreblocks:" .. nodepart if dont_reduce_node_count and coderblocks.has_moreblocks and minetest.registered_nodes [neednode] == nil and minetest.registered_nodes [fromnode] ~= nil then stairs.register_all (nodepart, fromnode, { cracky=3, not_in_creative_inventory=1 } , { "moreblocks_circle_stone_bricks.png" } , "Circle Stone Brick" , default.sound_stone()) end -- =================================================================== nodepart = "hardwood" neednode = "stairs:stair_" .. nodepart fromnode = "building_blocks:" .. nodepart if dont_reduce_node_count and coderblocks.has_moreblocks and minetest.registered_nodes [neednode] == nil and minetest.registered_nodes [fromnode] ~= nil then stairs.register_all (nodepart, fromnode, { choppy=1, not_in_creative_inventory=1 } , { "moreblocks_circle_stone_bricks.png" } , "Hardwood" , default.sound_wood()) end -- =================================================================== nodepart = "hemp_block" neednode = "stairs:stair_" .. nodepart fromnode = "farming:" .. nodepart if dont_reduce_node_count and minetest.registered_nodes [neednode] == nil and minetest.registered_nodes [fromnode] ~= nil then stairs.register_all (nodepart, fromnode, { choppy=2, snappy=2, oddly_breakable_by_hand=3, not_in_creative_inventory=1 } , { "farming_hemp_block.png" } , "Hemp Block" , default.node_sound_leaves_defaults()) end -- =================================================================== nodepart = "pumpkin" neednode = "stairs:stair_" .. nodepart fromnode = "farming:" .. nodepart if dont_reduce_node_count and minetest.registered_nodes [neednode] == nil and minetest.registered_nodes [fromnode] ~= nil then stairs.register_all (nodepart, fromnode, { choppy=2, snappy=2, oddly_breakable_by_hand=3, not_in_creative_inventory=1 } , { "farming_pumpkin.png" } , "Pumpkin" , default.node_sound_leaves_defaults()) end -- =================================================================== nodepart = "iron_stone_bricks" neednode = "stairs:stair_" .. nodepart fromnode = "moreblocks:" .. nodepart if dont_reduce_node_count and coderblocks.has_moreblocks and minetest.registered_nodes [neednode] == nil and minetest.registered_nodes [fromnode] ~= nil then stairs.register_all (nodepart, fromnode, { cracky=3, not_in_creative_inventory=1 } , { "moreblocks_iron_stone_bricks.png" } , "Iron Stone Bricks" , default.sound_stone()) end -- =================================================================== -- "stairs:stair_white" and related from "bakedclay:" nodepart = "white" neednode = "stairs:stair_" .. nodepart fromnode = "bakedclay:" .. nodepart if minetest.registered_nodes [neednode] == nil and minetest.registered_nodes [fromnode] ~= nil then stairs.register_all (nodepart, fromnode, { cracky=3, not_in_creative_inventory=1 } , { "baked_clay_white.png" } , "White Baked Clay" , default.sound_stone()) end -- =================================================================== -- "stairs:slab_stonesquare" and related from "poudlard:" nodepart = "stonesquare" neednode = "stairs:slab_" .. nodepart fromnode = "poudlard:" .. nodepart if dont_reduce_node_count and minetest.registered_nodes [neednode] == nil and minetest.registered_nodes [fromnode] ~= nil then stairs.register_all (nodepart, fromnode, { cracky=3, not_in_creative_inventory=1 } , { "poudlard_stonesquare.png" } , "Stone Square" , default.sound_stone()) end -- =================================================================== local color local wool_colors = { "red" , "white" , "blue" , "green" , "dark_green" , "black" , "cyan" , "orange" , "yellow" , "dark_grey" , } for _,color in pairs (wool_colors) do nodepart = "wool_" .. color neednode = "stairs:slope_" .. nodepart fromnode = "wool:" .. color if minetest.registered_nodes [neednode] == nil and minetest.registered_nodes [fromnode] ~= nil then stairs.register_all (nodepart, fromnode, { snappy=2, choppy=2, oddly_breakable_by_hand=3, not_in_creative_inventory=1, flammable=3, wool=1 } , { nodepart .. ".png" } , " Wool - " .. color , default.node_sound_defaults()) end end -- =================================================================== -- "stairs:slope_shingles_asphalt" and related from "homedecor:" nodepart = "shingles_asphalt" neednode = "stairs:slope_" .. nodepart fromnode = "homedecor:" .. nodepart if minetest.registered_nodes [neednode] == nil and minetest.registered_nodes [fromnode] ~= nil then stairs.register_all (nodepart, fromnode, { snappy=3, not_in_creative_inventory=1 } , { "homedecor_shingles_asphalt.png" } , "Asphalt Shingles" , default.sound_wood()) end -- =================================================================== -- "stairs:slope_shingles_terracotta" and related from "homedecor:" nodepart = "shingles_terracotta" neednode = "stairs:slope_" .. nodepart fromnode = "homedecor:" .. nodepart if minetest.registered_nodes [neednode] == nil and minetest.registered_nodes [fromnode] ~= nil then stairs.register_all (nodepart, fromnode, { snappy=3, not_in_creative_inventory=1 } , { "homedecor_shingles_terracotta.png" } , "Terracotta Shingles" , default.sound_wood()) end -- =================================================================== nodepart = "shingles_wood" neednode = "stairs:slope_" .. nodepart fromnode = "homedecor:" .. nodepart if minetest.registered_nodes [neednode] == nil and minetest.registered_nodes [fromnode] ~= nil then stairs.register_all (nodepart, fromnode, { snappy=3, not_in_creative_inventory=1 } , { "homedecor_shingles_wood.png" } , "Wood Shingles" , default.sound_wood()) end -- =================================================================== -- "stairs:stair_moonbrick" and related from "xdecor:" nodepart = "moonbrick" neednode = "stairs:stair_" .. nodepart fromnode = "xdecor:" .. nodepart if minetest.registered_nodes [neednode] == nil and minetest.registered_nodes [fromnode] ~= nil then stairs.register_all (nodepart, fromnode, { cracky=3, not_in_creative_inventory=1 } , { "xdecor_moonbrick.png" } , "Moon Brick" , default.sound_stone()) end -- =================================================================== -- RJK: This one is a special case due to inconsistent naming. -- neednode = "stairs:slope_tar" if minetest.registered_nodes [neednode] == nil and stairs.register_slope ~= nil then stairs.register_slope ("tar", "building_blocks:Tar" , { snappy=3 } , { "building_blocks_tar.png" } , "Tar") end -- =================================================================== cvt ("stairs:slab_button_0" , "stairs:slab_quartzblock" ) cvt ("stairs:slab_buttonFFFFFF" , "stairs:slab_quartzblock" ) cvt ("stairs:stair_buttonFFFFFF" , "stairs:stair_quartzblock" ) cvt ("stairs:slab_permafrost_with_stones" , "stairs:slab_stone" ) cvt ("stairs:stair_inner_stonebrick" , "moreblocks:stair_stonebrick_inner" ) cvt ("stairs:stair_outer_stonebrick" , "moreblocks:stair_stonebrick_outer" ) cvt ("stairs:slab_stone_brick" , "stairs:slab_stonebrick" ) cvt ("stairs:stair_stone_brick" , "stairs:stair_stonebrick" ) cvt ("stairs:slab_tree" , "stairs:slab_wood" ) cvt ( "stairs:slope_stone" , "moreblocks:slope_stone" ) cvt ("stairs:stair_tree" , "stairs:stair_wood" ) cvt ("default:junglewood_innerstair" , "stairs:stair_inner_junglewood" ) -- =================================================================== cvt ( "stairs:slope_cobble" , "moreblocks:slope_cobble" ) cvt ( "stairs:slope_desert_stone" , "moreblocks:slope_desert_stone" ) cvt ( "stairs:slope_junglewood" , "moreblocks:slope_junglewood" ) cvt ( "stairs:slope_sandstone" , "moreblocks:slope_sandstone" ) -- =================================================================== -- End of module.