242 lines
5.8 KiB
Lua
242 lines
5.8 KiB
Lua
-- Default nodes for Itemshelf mod
|
|
-- By Zorman2000
|
|
|
|
local default_shelf = {
|
|
type = "fixed",
|
|
fixed = {
|
|
{-0.5, -0.5, 0.4375, 0.5, 0.5, 0.5}, -- NodeBox1
|
|
{-0.5, -0.5, -0.5, -0.4375, 0.5, 0.4375}, -- NodeBox2
|
|
{-0.4375, -0.5, -0.5, 0.4375, -0.4375, 0.4375}, -- NodeBox3
|
|
{0.4375, -0.5, -0.5, 0.5, 0.5, 0.4375}, -- NodeBox4
|
|
{-0.4375, 0.4375, -0.5, 0.4375, 0.5, 0.4375}, -- NodeBox5
|
|
{-0.4375, -0.0625, -0.5, 0.4375, 0.0625, 0.4375}, -- NodeBox6
|
|
}
|
|
}
|
|
|
|
local default_half_shelf = {
|
|
type = "fixed",
|
|
fixed = {
|
|
{-0.5, -0.5, 0.4375, 0.5, 0.5, 0.5}, -- NodeBox1
|
|
{-0.5, -0.5, -0.125, -0.4375, 0.5, 0.5}, -- NodeBox2
|
|
{0.4375, -0.5, -0.125, 0.5, 0.5, 0.5}, -- NodeBox3
|
|
{-0.5, -0.0625, -0.125, 0.5, 0.0625, 0.5}, -- NodeBox4
|
|
{-0.5, 0.4375, -0.125, 0.5, 0.5, 0.5}, -- NodeBox5
|
|
{-0.5, -0.5, -0.125, 0.5, -0.4375, 0.5}, -- NodeBox6
|
|
}
|
|
}
|
|
|
|
local default_half_shelf_open = {
|
|
type = "fixed",
|
|
fixed = {
|
|
{-0.5, -0.5, -0.125, -0.4375, 0.5, 0.5}, -- NodeBox2
|
|
{0.4375, -0.5, -0.125, 0.5, 0.5, 0.5}, -- NodeBox3
|
|
{-0.5, -0.0625, -0.125, 0.5, 0.0625, 0.5}, -- NodeBox4
|
|
{-0.5, 0.4375, -0.125, 0.5, 0.5, 0.5}, -- NodeBox5
|
|
{-0.5, -0.5, -0.125, 0.5, -0.4375, 0.5}, -- NodeBox6
|
|
}
|
|
}
|
|
|
|
itemshelf.register_shelf("small_shelf", {
|
|
description = "Small Wooden Shelf",
|
|
textures = {
|
|
"default_wood.png",
|
|
"default_wood.png",
|
|
"default_wood.png",
|
|
"default_wood.png",
|
|
"default_wood.png",
|
|
"default_wood.png"
|
|
},
|
|
nodebox = default_shelf,
|
|
capacity = 4,
|
|
shown_items = 4
|
|
})
|
|
|
|
itemshelf.register_shelf("large_shelf", {
|
|
description = "Large Wooden Shelf",
|
|
textures = {
|
|
"default_wood.png",
|
|
"default_wood.png",
|
|
"default_wood.png",
|
|
"default_wood.png",
|
|
"default_wood.png",
|
|
"default_wood.png"
|
|
},
|
|
nodebox = default_shelf,
|
|
capacity = 6,
|
|
shown_items = 6
|
|
})
|
|
|
|
itemshelf.register_shelf("half_depth_shelf_small", {
|
|
description = "Small Wooden Half-Depth Shelf",
|
|
textures = {
|
|
"default_wood.png",
|
|
"default_wood.png",
|
|
"default_wood.png",
|
|
"default_wood.png",
|
|
"default_wood.png",
|
|
"default_wood.png"
|
|
},
|
|
nodebox = default_half_shelf,
|
|
capacity = 4,
|
|
shown_items = 4,
|
|
half_depth = true,
|
|
})
|
|
|
|
itemshelf.register_shelf("half_depth_shelf_large", {
|
|
description = "Large Wooden Half-Depth Shelf",
|
|
textures = {
|
|
"default_wood.png",
|
|
"default_wood.png",
|
|
"default_wood.png",
|
|
"default_wood.png",
|
|
"default_wood.png",
|
|
"default_wood.png"
|
|
},
|
|
nodebox = default_half_shelf,
|
|
capacity = 6,
|
|
shown_items = 6,
|
|
half_depth = true,
|
|
})
|
|
|
|
itemshelf.register_shelf("half_depth_open_shelf", {
|
|
description = "Small Wooden Half-Depth Open-Back Shelf",
|
|
textures = {
|
|
"default_wood.png",
|
|
"default_wood.png",
|
|
"default_wood.png",
|
|
"default_wood.png",
|
|
"default_wood.png",
|
|
"default_wood.png"
|
|
},
|
|
nodebox = default_half_shelf_open,
|
|
capacity = 4,
|
|
shown_items = 4,
|
|
half_depth = true,
|
|
})
|
|
|
|
itemshelf.register_shelf("half_depth_open_shelf_large", {
|
|
description = "Large Wooden Half-Depth Open-Back Shelf",
|
|
textures = {
|
|
"default_wood.png",
|
|
"default_wood.png",
|
|
"default_wood.png",
|
|
"default_wood.png",
|
|
"default_wood.png",
|
|
"default_wood.png"
|
|
},
|
|
nodebox = default_half_shelf_open,
|
|
capacity = 6,
|
|
shown_items = 6,
|
|
half_depth = true,
|
|
})
|
|
-----------------------------------------
|
|
|
|
|
|
minetest.register_craft({
|
|
output = "itemshelf:small_shelf",
|
|
recipe = {
|
|
{"group:wood", "group:wood", "group:wood"},
|
|
{"stairs:slab_wood", "default:chest", "stairs:slab_wood"},
|
|
{"group:wood", "group:wood", "group:wood"},
|
|
},
|
|
})
|
|
|
|
-- minetest.register_craft({
|
|
-- output = "itemshelf:large_shelf",
|
|
-- recipe = {
|
|
-- {"group:wood", "group:wood", "group:wood"},
|
|
-- {"default:chest", "stairs:slab_wood", "default:chest"},
|
|
-- {"group:wood", "group:wood", "group:wood"},
|
|
-- },
|
|
-- })
|
|
-----------------------------------------
|
|
minetest.register_craft({
|
|
output = "itemshelf:half_depth_open_shelf",
|
|
recipe = {
|
|
{"stairs:slab_wood", "stairs:slab_wood", "stairs:slab_wood"},
|
|
{"stairs:slab_wood", "default:chest", "stairs:slab_wood"},
|
|
{"stairs:slab_wood", "stairs:slab_wood", "stairs:slab_wood"},
|
|
},
|
|
})
|
|
|
|
-- minetest.register_craft({
|
|
-- output = "itemshelf:half_depth_open_shelf_large",
|
|
-- recipe = {
|
|
-- {"stairs:slab_wood", "stairs:slab_wood", "stairs:slab_wood"},
|
|
-- {"default:chest", "stairs:slab_wood", "default:chest"},
|
|
-- {"stairs:slab_wood", "stairs:slab_wood", "stairs:slab_wood"},
|
|
-- },
|
|
-- })
|
|
-----------------------------------------
|
|
|
|
minetest.register_craft({
|
|
output = "itemshelf:half_depth_shelf_small",
|
|
recipe = {
|
|
{"stairs:slab_wood", "stairs:slab_wood", "stairs:slab_wood"},
|
|
{"group:wood", "default:chest", "group:wood"},
|
|
{"stairs:slab_wood", "stairs:slab_wood", "stairs:slab_wood"},
|
|
},
|
|
})
|
|
|
|
-- minetest.register_craft({
|
|
-- output = "itemshelf:half_depth_shelf_large",
|
|
-- recipe = {
|
|
-- {"stairs:slab_wood", "stairs:slab_wood", "stairs:slab_wood"},
|
|
-- {"default:chest", "group:wood", "default:chest"},
|
|
-- {"stairs:slab_wood", "stairs:slab_wood", "stairs:slab_wood"},
|
|
-- },
|
|
-- })
|
|
-----------------------------------------
|
|
minetest.register_craft({
|
|
type = "shapeless",
|
|
output = "itemshelf:small_shelf",
|
|
recipe = {"itemshelf:large_shelf"},
|
|
})
|
|
minetest.register_craft({
|
|
type = "shapeless",
|
|
output = "itemshelf:large_shelf",
|
|
recipe = {"itemshelf:small_shelf"},
|
|
})
|
|
|
|
|
|
-----------------------------------------
|
|
|
|
minetest.register_craft({
|
|
type = "shapeless",
|
|
output = "itemshelf:half_depth_shelf_small",
|
|
recipe = {"itemshelf:half_depth_shelf_large"},
|
|
})
|
|
|
|
|
|
minetest.register_craft({
|
|
type = "shapeless",
|
|
output = "itemshelf:half_depth_shelf_large",
|
|
recipe = {"itemshelf:half_depth_shelf_small"},
|
|
})
|
|
|
|
|
|
-----------------------------------------
|
|
|
|
|
|
|
|
|
|
minetest.register_craft({
|
|
type = "shapeless",
|
|
output = "itemshelf:half_depth_open_shelf",
|
|
recipe = {"itemshelf:half_depth_open_shelf_large"},
|
|
})
|
|
|
|
|
|
minetest.register_craft({
|
|
type = "shapeless",
|
|
output = "itemshelf:half_depth_open_shelf_large",
|
|
recipe = {"itemshelf:half_depth_open_shelf"},
|
|
})
|
|
|
|
|
|
|
|
|
|
-----------------------------------------
|
|
|
|
--petz:elephant_tusk
|