Import source (dev state between 1.2.0 and 1.3.0)
[minetest_tutorial_subgame.git] / mods / cottages / nodes_furniture.lua
blob77be62542fe310301d96e36c57bcb3a79b3c46a8
1 ---------------------------------------------------------------------------------------
2 -- furniture
3 ---------------------------------------------------------------------------------------
4 -- contains:
5 -- * a bed seperated into foot and head reagion so that it can be placed manually; it has
6 -- no other functionality than decoration!
7 -- * a sleeping mat - mostly for NPC that cannot afford a bet yet
8 -- * bench - if you don't have 3dforniture:chair, then this is the next best thing
9 -- * table - very simple one
10 -- * shelf - for stroring things; this one is 3d
11 -- * stovepipe - so that the smoke from the furnace can get away
12 -- * washing place - put it over a water source and you can 'wash' yourshelf
13 ---------------------------------------------------------------------------------------
15 -- the basic version of a bed - a sleeping mat
16 -- to facilitate upgrade path straw mat -> sleeping mat -> bed, this uses a nodebox
17 minetest.register_node("cottages:sleeping_mat", {
18 description = "sleeping matg",
19 drawtype = 'nodebox',
20 tiles = { 'cottages_sleepingmat.png' }, -- done by VanessaE
21 wield_image = 'cottages_sleepingmat.png',
22 inventory_image = 'cottages_sleepingmat.png',
23 sunlight_propagates = true,
24 paramtype = 'light',
25 paramtype2 = "facedir",
26 is_ground_content = true,
27 walkable = false,
28 groups = { immortal=1 },
29 sounds = default.node_sound_leaves_defaults(),
30 selection_box = {
31 type = "wallmounted",
33 node_box = {
34 type = "fixed",
35 fixed = {
36 {-0.48, -0.5,-0.48, 0.48, -0.45, 0.48},
39 selection_box = {
40 type = "fixed",
41 fixed = {
42 {-0.48, -0.5,-0.48, 0.48, -0.25, 0.48},
49 -- furniture; possible replacement: 3dforniture:chair
50 minetest.register_node("cottages:bench", {
51 drawtype = "nodebox",
52 description = "simple wooden bench",
53 tiles = {"cottages_minimal_wood.png", "cottages_minimal_wood.png", "cottages_minimal_wood.png", "cottages_minimal_wood.png", "cottages_minimal_wood.png", "cottages_minimal_wood.png"},
54 paramtype = "light",
55 paramtype2 = "facedir",
56 groups = { immortal=1 },
57 sounds = default.node_sound_wood_defaults(),
58 node_box = {
59 type = "fixed",
60 fixed = {
61 -- sitting area
62 {-0.5, -0.15, 0.1, 0.5, -0.05, 0.5},
64 -- stützen
65 {-0.4, -0.5, 0.2, -0.3, -0.15, 0.4},
66 { 0.3, -0.5, 0.2, 0.4, -0.15, 0.4},
69 selection_box = {
70 type = "fixed",
71 fixed = {
72 {-0.5, -0.5, 0, 0.5, 0, 0.5},
78 -- a simple table; possible replacement: 3dforniture:table
79 minetest.register_node("cottages:table", {
80 description = "table",
81 drawtype = "nodebox",
82 -- top, bottom, side1, side2, inner, outer
83 tiles = {"cottages_minimal_wood.png"},
84 paramtype = "light",
85 paramtype2 = "facedir",
86 is_ground_content = true,
87 groups = { immortal=1 },
88 sounds = default.node_sound_wood_defaults(),
89 node_box = {
90 type = "fixed",
91 fixed = {
92 { -0.1, -0.5, -0.1, 0.1, 0.3, 0.1},
93 { -0.5, 0.3, -0.5, 0.5, 0.4, 0.5},
96 selection_box = {
97 type = "fixed",
98 fixed = {
99 { -0.5, -0.5, -0.5, 0.5, 0.4, 0.5},