mirror of
https://github.com/mt-mods/homedecor_modpack.git
synced 2024-12-22 16:10:18 +01:00
move old 3dforniture-style table into the proper mod
This commit is contained in:
parent
c70fb1a1ed
commit
950210a6e3
@ -1,38 +1,5 @@
|
|||||||
local S = minetest.get_translator("homedecor_furniture")
|
local S = minetest.get_translator("homedecor_furniture")
|
||||||
|
|
||||||
local table_colors = {
|
|
||||||
{ "", S("Table"), homedecor.plain_wood },
|
|
||||||
{ "_mahogany", S("Mahogany Table"), homedecor.mahogany_wood },
|
|
||||||
{ "_white", S("White Table"), homedecor.white_wood }
|
|
||||||
}
|
|
||||||
|
|
||||||
for _, t in ipairs(table_colors) do
|
|
||||||
local suffix, desc, texture = unpack(t)
|
|
||||||
|
|
||||||
homedecor.register("table"..suffix, {
|
|
||||||
description = desc,
|
|
||||||
tiles = { texture },
|
|
||||||
node_box = {
|
|
||||||
type = "fixed",
|
|
||||||
fixed = {
|
|
||||||
{ -0.4, -0.5, -0.4, -0.3, 0.4, -0.3 },
|
|
||||||
{ 0.3, -0.5, -0.4, 0.4, 0.4, -0.3 },
|
|
||||||
{ -0.4, -0.5, 0.3, -0.3, 0.4, 0.4 },
|
|
||||||
{ 0.3, -0.5, 0.3, 0.4, 0.4, 0.4 },
|
|
||||||
{ -0.5, 0.4, -0.5, 0.5, 0.5, 0.5 },
|
|
||||||
{ -0.4, -0.2, -0.3, -0.3, -0.1, 0.3 },
|
|
||||||
{ 0.3, -0.2, -0.4, 0.4, -0.1, 0.3 },
|
|
||||||
{ -0.3, -0.2, -0.4, 0.4, -0.1, -0.3 },
|
|
||||||
{ -0.3, -0.2, 0.3, 0.3, -0.1, 0.4 },
|
|
||||||
},
|
|
||||||
},
|
|
||||||
groups = {snappy=2,choppy=2,oddly_breakable_by_hand=2},
|
|
||||||
sounds = default.node_sound_wood_defaults(),
|
|
||||||
})
|
|
||||||
end
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
local ob_cbox = {
|
local ob_cbox = {
|
||||||
type = "fixed",
|
type = "fixed",
|
||||||
fixed = { -0.5, -0.5, 0, 0.5, 0.5, 0.5 }
|
fixed = { -0.5, -0.5, 0, 0.5, 0.5, 0.5 }
|
||||||
@ -72,60 +39,6 @@ homedecor.register("wall_shelf", {
|
|||||||
|
|
||||||
-- Crafts
|
-- Crafts
|
||||||
|
|
||||||
|
|
||||||
minetest.register_craft({
|
|
||||||
output = "homedecor:table",
|
|
||||||
recipe = {
|
|
||||||
{ "group:wood","group:wood", "group:wood" },
|
|
||||||
{ "group:stick", "", "group:stick" },
|
|
||||||
},
|
|
||||||
})
|
|
||||||
|
|
||||||
minetest.register_craft({
|
|
||||||
type = "shapeless",
|
|
||||||
output = "homedecor:table_mahogany",
|
|
||||||
recipe = {
|
|
||||||
"homedecor:table",
|
|
||||||
"dye:brown",
|
|
||||||
},
|
|
||||||
})
|
|
||||||
|
|
||||||
minetest.register_craft({
|
|
||||||
type = "shapeless",
|
|
||||||
output = "homedecor:table_mahogany",
|
|
||||||
recipe = {
|
|
||||||
"homedecor:table",
|
|
||||||
"unifieddyes:dark_orange",
|
|
||||||
},
|
|
||||||
})
|
|
||||||
|
|
||||||
minetest.register_craft({
|
|
||||||
type = "shapeless",
|
|
||||||
output = "homedecor:table_white",
|
|
||||||
recipe = {
|
|
||||||
"homedecor:table",
|
|
||||||
"dye:white",
|
|
||||||
},
|
|
||||||
})
|
|
||||||
|
|
||||||
minetest.register_craft({
|
|
||||||
type = "fuel",
|
|
||||||
recipe = "homedecor:table",
|
|
||||||
burntime = 30,
|
|
||||||
})
|
|
||||||
|
|
||||||
minetest.register_craft({
|
|
||||||
type = "fuel",
|
|
||||||
recipe = "homedecor:table_mahogany",
|
|
||||||
burntime = 30,
|
|
||||||
})
|
|
||||||
|
|
||||||
minetest.register_craft({
|
|
||||||
type = "fuel",
|
|
||||||
recipe = "homedecor:table_white",
|
|
||||||
burntime = 30,
|
|
||||||
})
|
|
||||||
|
|
||||||
minetest.register_craft({
|
minetest.register_craft({
|
||||||
output = "homedecor:standing_lamp_off",
|
output = "homedecor:standing_lamp_off",
|
||||||
recipe = {
|
recipe = {
|
||||||
|
@ -124,6 +124,39 @@ for i, mat in ipairs(tabletop_materials) do
|
|||||||
|
|
||||||
end
|
end
|
||||||
|
|
||||||
|
-- old-style tables that used to be from 3dforniture.
|
||||||
|
|
||||||
|
local table_colors = {
|
||||||
|
{ "", S("Table"), homedecor.plain_wood },
|
||||||
|
{ "_mahogany", S("Mahogany Table"), homedecor.mahogany_wood },
|
||||||
|
{ "_white", S("White Table"), homedecor.white_wood }
|
||||||
|
}
|
||||||
|
|
||||||
|
for _, t in ipairs(table_colors) do
|
||||||
|
local suffix, desc, texture = unpack(t)
|
||||||
|
|
||||||
|
homedecor.register("table"..suffix, {
|
||||||
|
description = desc,
|
||||||
|
tiles = { texture },
|
||||||
|
node_box = {
|
||||||
|
type = "fixed",
|
||||||
|
fixed = {
|
||||||
|
{ -0.4, -0.5, -0.4, -0.3, 0.4, -0.3 },
|
||||||
|
{ 0.3, -0.5, -0.4, 0.4, 0.4, -0.3 },
|
||||||
|
{ -0.4, -0.5, 0.3, -0.3, 0.4, 0.4 },
|
||||||
|
{ 0.3, -0.5, 0.3, 0.4, 0.4, 0.4 },
|
||||||
|
{ -0.5, 0.4, -0.5, 0.5, 0.5, 0.5 },
|
||||||
|
{ -0.4, -0.2, -0.3, -0.3, -0.1, 0.3 },
|
||||||
|
{ 0.3, -0.2, -0.4, 0.4, -0.1, 0.3 },
|
||||||
|
{ -0.3, -0.2, -0.4, 0.4, -0.1, -0.3 },
|
||||||
|
{ -0.3, -0.2, 0.3, 0.3, -0.1, 0.4 },
|
||||||
|
},
|
||||||
|
},
|
||||||
|
groups = {snappy=2,choppy=2,oddly_breakable_by_hand=2},
|
||||||
|
sounds = default.node_sound_wood_defaults(),
|
||||||
|
})
|
||||||
|
end
|
||||||
|
|
||||||
-- crafting
|
-- crafting
|
||||||
|
|
||||||
minetest.register_craft( {
|
minetest.register_craft( {
|
||||||
@ -149,8 +182,6 @@ minetest.register_craft( {
|
|||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
|
||||||
--
|
|
||||||
|
|
||||||
minetest.register_craft( {
|
minetest.register_craft( {
|
||||||
output = "homedecor:wood_table_small_round_b 15",
|
output = "homedecor:wood_table_small_round_b 15",
|
||||||
recipe = {
|
recipe = {
|
||||||
@ -243,6 +274,59 @@ for _, shape in ipairs (table_shapes) do
|
|||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
minetest.register_craft({
|
||||||
|
output = "homedecor:table",
|
||||||
|
recipe = {
|
||||||
|
{ "group:wood","group:wood", "group:wood" },
|
||||||
|
{ "group:stick", "", "group:stick" },
|
||||||
|
},
|
||||||
|
})
|
||||||
|
|
||||||
|
minetest.register_craft({
|
||||||
|
type = "shapeless",
|
||||||
|
output = "homedecor:table_mahogany",
|
||||||
|
recipe = {
|
||||||
|
"homedecor:table",
|
||||||
|
"dye:brown",
|
||||||
|
},
|
||||||
|
})
|
||||||
|
|
||||||
|
minetest.register_craft({
|
||||||
|
type = "shapeless",
|
||||||
|
output = "homedecor:table_mahogany",
|
||||||
|
recipe = {
|
||||||
|
"homedecor:table",
|
||||||
|
"unifieddyes:dark_orange",
|
||||||
|
},
|
||||||
|
})
|
||||||
|
|
||||||
|
minetest.register_craft({
|
||||||
|
type = "shapeless",
|
||||||
|
output = "homedecor:table_white",
|
||||||
|
recipe = {
|
||||||
|
"homedecor:table",
|
||||||
|
"dye:white",
|
||||||
|
},
|
||||||
|
})
|
||||||
|
|
||||||
|
minetest.register_craft({
|
||||||
|
type = "fuel",
|
||||||
|
recipe = "homedecor:table",
|
||||||
|
burntime = 30,
|
||||||
|
})
|
||||||
|
|
||||||
|
minetest.register_craft({
|
||||||
|
type = "fuel",
|
||||||
|
recipe = "homedecor:table_mahogany",
|
||||||
|
burntime = 30,
|
||||||
|
})
|
||||||
|
|
||||||
|
minetest.register_craft({
|
||||||
|
type = "fuel",
|
||||||
|
recipe = "homedecor:table_white",
|
||||||
|
burntime = 30,
|
||||||
|
})
|
||||||
|
|
||||||
-- recycling
|
-- recycling
|
||||||
|
|
||||||
minetest.register_craft({
|
minetest.register_craft({
|
||||||
@ -304,4 +388,3 @@ minetest.register_craft({
|
|||||||
"homedecor:wood_table_large"
|
"homedecor:wood_table_large"
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user