Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- local riventest_nodes = { -- Default stairs/slabs/panels/microblocks:
- "rt1",
- "rt2",
- "rt5",
- "rt3",
- "rt4",
- "rt7",
- "rt8",
- "rt10",
- "rt11",
- "rt12",
- "wood",
- "inward-squared brownstone",
- "flower-patterned metal",
- "lined brownestone",
- "metal block",
- "golden block",
- "outward-squared brownstone",
- "cobble brightstone",
- "rusted metal block",
- "flower-patterned brightstone",
- "mosaic brightstone",
- "bluewood"
- }
- for _, name in pairs(cave_nodes) do
- local nodename = "riventest:"..name
- local a,b = string.find(name, ":")
- if b then
- nodename = name
- name = string.sub(name, b+1)
- end
- local ndef = minetest.registered_nodes[nodename]
- if ndef then
- local drop
- if type(ndef.drop) == "string" then
- drop = ndef.drop:sub((b or 8)+1)
- end
- local tiles = ndef.tiles
- if #ndef.tiles > 1 and ndef.drawtype:find("glass") then
- tiles = { ndef.tiles[1] }
- end
- stairsplus:register_all("riventest", name, nodename, {
- description = ndef.description,
- drop = drop,
- groups = ndef.groups,
- sounds = ndef.sounds,
- tiles = tiles,
- sunlight_propagates = true,
- light_source = ndef.light_source
- })
- end
- end
Advertisement
Add Comment
Please, Sign In to add comment