Alias empty shelf if moreblocks is enabled (#108)

This commit is contained in:
Vanessa Dannenberg 2019-07-10 14:27:30 -04:00 committed by SmallJoker
parent 8020eb1863
commit f78fce959c
2 changed files with 19 additions and 13 deletions

View File

@ -95,11 +95,15 @@ register_storage("cabinet_half", "Half Wooden Cabinet", {
"xdecor_half_cabinet_sides.png", "xdecor_half_cabinet_front.png"} "xdecor_half_cabinet_sides.png", "xdecor_half_cabinet_front.png"}
}) })
if minetest.get_modpath("moreblocks") then
minetest.register_alias("xdecor:empty_shelf", "moreblocks:empty_shelf")
else
register_storage("empty_shelf", "Empty Shelf", { register_storage("empty_shelf", "Empty Shelf", {
on_rotate = screwdriver.rotate_simple, on_rotate = screwdriver.rotate_simple,
tiles = {"default_wood.png", "default_wood.png", "default_wood.png", tiles = {"default_wood.png", "default_wood.png", "default_wood.png",
"default_wood.png", "default_wood.png^xdecor_empty_shelf.png"} "default_wood.png", "default_wood.png^xdecor_empty_shelf.png"}
}) })
end
register_storage("multishelf", "Multi Shelf", { register_storage("multishelf", "Multi Shelf", {
on_rotate = screwdriver.rotate_simple, on_rotate = screwdriver.rotate_simple,

View File

@ -95,6 +95,7 @@ minetest.register_craft({
} }
}) })
if not minetest.get_modpath("moreblocks") then
minetest.register_craft({ minetest.register_craft({
output = "xdecor:empty_shelf", output = "xdecor:empty_shelf",
recipe = { recipe = {
@ -103,6 +104,7 @@ minetest.register_craft({
{"group:wood", "group:wood", "group:wood"} {"group:wood", "group:wood", "group:wood"}
} }
}) })
end
minetest.register_craft({ minetest.register_craft({
output = "xdecor:enderchest", output = "xdecor:enderchest",