add stair and slab groups

This commit is contained in:
DS-Minetest 2017-08-22 16:15:53 +02:00 committed by sofar
parent 780df105ea
commit 4c767ad7ff
2 changed files with 6 additions and 0 deletions

View File

@ -96,6 +96,9 @@ function stairsplus:register_slab(modname, subname, recipeitem, fields)
def.paramtype2 = def.paramtype2 or "facedir"
def.on_place = minetest.rotate_node
def.groups = stairsplus:prepare_groups(fields.groups)
if alternate == "" then
def.groups.slab = 1
end
if fields.drop and not (type(fields.drop) == "table") then
def.drop = modname.. ":slab_" .. fields.drop .. alternate
end

View File

@ -136,6 +136,9 @@ function stairsplus:register_stair(modname, subname, recipeitem, fields)
def.on_place = minetest.rotate_node
def.description = desc
def.groups = stairsplus:prepare_groups(fields.groups)
if alternate == "" then
def.groups.stair = 1
end
if fields.drop and not (type(fields.drop) == "table") then
def.drop = modname .. ":stair_" .. fields.drop .. alternate
end