summaryrefslogtreecommitdiff
path: root/homedecor_laundry/init.lua
blob: ee59c8c7861f0671ad701743a03446a5443297a0 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
-- laundry devices

homedecor.register("washing_machine", {
	description = "Washing Machine",
	tiles = {
		"homedecor_washing_machine_top.png",
		"homedecor_washing_machine_bottom.png",
		"homedecor_washing_machine_sides.png",
		"homedecor_washing_machine_sides.png^[transformFX",
		"homedecor_washing_machine_back.png",
		"homedecor_washing_machine_front.png"
	},
	node_box = {
		type = "fixed",
		fixed = {
			{-0.5, -0.5, -0.5, 0.5, 0.375, 0.375},
			{-0.5, -0.5, 0.3125, 0.5, 0.5, 0.5},
		}
	},
	selection_box = { type = "regular" },
	groups = { snappy = 3 },
})

homedecor.register("dryer", {
	description = "Tumble dryer",
	tiles = {
		"homedecor_dryer_top.png",
		"homedecor_dryer_bottom.png",
		"homedecor_dryer_sides.png",
		"homedecor_dryer_sides.png^[transformFX",
		"homedecor_dryer_back.png",
		"homedecor_dryer_front.png"
	},
	node_box = {
		type = "fixed",
		fixed = {
			{-0.5, -0.5, -0.5, 0.5, 0.375, 0.375},
			{-0.5, -0.5, 0.3125, 0.5, 0.5, 0.5},
		}
	},
	selection_box = { type = "regular" },
	groups = { snappy = 3 },
})

local ib_cbox = {
	type = "fixed",
	fixed = { -6/16, -8/16, -4/16, 17/16, 4/16, 4/16 }
}

homedecor.register("ironing_board", {
	description = "Ironing board",
	mesh = "homedecor_ironing_board.obj",
	tiles = {
		"wool_grey.png",
		{ name = "homedecor_generic_metal.png", color = homedecor.color_med_grey },
	},
	expand = {right = "placeholder"},
	groups = { snappy = 3 },
	selection_box = ib_cbox,
	collision_box = ib_cbox
})

-- crafting


-- laundry stuff

minetest.register_craft( {
    output = "homedecor:washing_machine",
    recipe = {
		{ "default:steel_ingot", "default:steel_ingot", "basic_materials:ic" },
		{ "default:steel_ingot", "bucket:bucket_water", "default:steel_ingot" },
		{ "default:steel_ingot", "basic_materials:motor", "default:steel_ingot" }
    },
})

minetest.register_craft( {
    output = "homedecor:washing_machine",
    recipe = {
		{ "default:steel_ingot", "default:steel_ingot", "basic_materials:ic" },
		{ "default:steel_ingot", "bucket:bucket_water", "default:steel_ingot" },
		{ "default:steel_ingot", "basic_materials:motor", "default:steel_ingot" }
    },
})

minetest.register_craft( {
    output = "homedecor:dryer",
    recipe = {
		{ "default:steel_ingot", "default:steel_ingot", "basic_materials:ic" },
		{ "default:steel_ingot", "bucket:bucket_empty", "basic_materials:motor" },
		{ "default:steel_ingot", "basic_materials:heating_element", "default:steel_ingot" }
    },
})

minetest.register_craft( {
    output = "homedecor:dryer",
    recipe = {
		{ "default:steel_ingot", "default:steel_ingot", "basic_materials:ic" },
		{ "default:steel_ingot", "bucket:bucket_empty", "basic_materials:motor" },
		{ "default:steel_ingot", "basic_materials:heating_element", "default:steel_ingot" }
    },
})

minetest.register_craft( {
    output = "homedecor:ironing_board",
    recipe = {
		{ "wool:grey", "wool:grey", "wool:grey"},
		{ "", "default:steel_ingot", "" },
		{ "default:steel_ingot", "", "default:steel_ingot" }
    },
})