Made all wooden and glass tabletops nodebox-based.
Several textures renamed to suit, a few new ones added.
							
								
								
									
										554
									
								
								tables.lua
									
									
									
									
									
								
							
							
						
						| @@ -9,153 +9,418 @@ else | |||||||
|     S = function ( s ) return s end |     S = function ( s ) return s end | ||||||
| end | end | ||||||
|  |  | ||||||
| minetest.register_node('homedecor:glass_table_large', { | materials = { | ||||||
| 	description = S("Large Glass Table Piece"), | 	{"glass","Glass"}, | ||||||
| 	drawtype = 'signlike', | 	{"wood","Wood"} | ||||||
| 	tiles = { 'homedecor_glass_table_large.png' }, | } | ||||||
| 	wield_image = 'homedecor_glass_table_large.png', |  | ||||||
| 	inventory_image = 'homedecor_glass_table_large.png', |  | ||||||
| 	sunlight_propagates = true, |  | ||||||
| 	paramtype = 'light', |  | ||||||
| 	walkable = false, |  | ||||||
| 	groups = { snappy = 3 }, |  | ||||||
| 	sounds = default.node_sound_leaves_defaults(), |  | ||||||
| 	paramtype2 = "wallmounted", |  | ||||||
| 	is_ground_content = true, |  | ||||||
|         selection_box = { |  | ||||||
| 			type = "wallmounted", |  | ||||||
|                          --wall_top = <default> |  | ||||||
|                          --wall_bottom = <default> |  | ||||||
|                          --wall_side = <default> |  | ||||||
|                         }, |  | ||||||
| }) |  | ||||||
|  |  | ||||||
| minetest.register_node('homedecor:glass_table_small_round', { | for i in ipairs(materials) do | ||||||
| 	description = S("Glass Table (Small, Round)"), | 	local m = materials[i][1] | ||||||
| 	drawtype = 'signlike', | 	local d = materials[i][2] | ||||||
| 	tiles = { 'homedecor_glass_table_small_round.png' }, | 	local s = nil | ||||||
| 	wield_image = 'homedecor_glass_table_small_round.png', |  | ||||||
| 	inventory_image = 'homedecor_glass_table_small_round.png', |  | ||||||
| 	sunlight_propagates = true, |  | ||||||
| 	paramtype = 'light', |  | ||||||
| 	paramtype2 = "wallmounted", |  | ||||||
| 	is_ground_content = true, |  | ||||||
| 	walkable = false, |  | ||||||
| 	groups = { snappy = 3 }, |  | ||||||
| 	sounds = default.node_sound_leaves_defaults(), |  | ||||||
|         selection_box = { |  | ||||||
| 			type = "wallmounted", |  | ||||||
|                          --wall_top = <default> |  | ||||||
|                          --wall_bottom = <default> |  | ||||||
|                          --wall_side = <default> |  | ||||||
|                         }, |  | ||||||
| }) |  | ||||||
|  |  | ||||||
| minetest.register_node('homedecor:glass_table_small_square', { | 	if m == "glass" then | ||||||
| 	description = S("Glass Table (Small, Square)"), | 		s = default.node_sound_glass_defaults() | ||||||
| 	drawtype = 'signlike', | 	else | ||||||
| 	tiles = { 'homedecor_glass_table_small_square.png' }, | 		s = default.node_sound_wood_defaults() | ||||||
| 	wield_image = 'homedecor_glass_table_small_square.png', | 	end | ||||||
| 	inventory_image = 'homedecor_glass_table_small_square.png', |  | ||||||
| 	sunlight_propagates = true, | -- small square tables | ||||||
| 	paramtype = 'light', |  | ||||||
| 	paramtype2 = "wallmounted", | 	minetest.register_node("homedecor:"..m.."_table_small_square_b", { | ||||||
| 	is_ground_content = true, | 		description = S(d.." Table (Small, Square)"), | ||||||
| 	walkable = false, | 		drawtype = 'nodebox', | ||||||
| 	groups = { snappy = 3 }, | 		tiles = { | ||||||
| 	sounds = default.node_sound_leaves_defaults(), | 			'homedecor_'..m..'_table_small_square_tb.png', | ||||||
|         selection_box = { | 			'homedecor_'..m..'_table_small_square_tb.png', | ||||||
| 			type = "wallmounted", | 			'homedecor_'..m..'_table_small_square_edges.png', | ||||||
|                          --wall_top = <default> | 			'homedecor_'..m..'_table_small_square_edges.png', | ||||||
|                          --wall_bottom = <default> | 			'homedecor_'..m..'_table_small_square_edges.png', | ||||||
|                          --wall_side = <default> | 			'homedecor_'..m..'_table_small_square_edges.png' | ||||||
|                         }, | 		}, | ||||||
| }) | 		wield_image = 'homedecor_'..m..'_table_small_square_tb.png', | ||||||
|  | 		inventory_image = 'homedecor_'..m..'_table_small_square_tb.png', | ||||||
|  | 		sunlight_propagates = true, | ||||||
|  | 		paramtype = 'light', | ||||||
|  | 		walkable = true, | ||||||
|  | 		groups = { snappy = 3 }, | ||||||
|  | 		sounds = s, | ||||||
|  | 		paramtype2 = "facedir", | ||||||
|  |  | ||||||
|  | 		node_box = { | ||||||
|  | 			type = "fixed", | ||||||
|  | 			fixed = { | ||||||
|  | 				{ -0.4375, -0.5, -0.5,     0.4375, -0.4375, 0.5    }, | ||||||
|  | 				{ -0.5,    -0.5, -0.4375,  0.5,    -0.4375, 0.4375 } | ||||||
|  | 			}, | ||||||
|  | 		}, | ||||||
|  | 		selection_box = { | ||||||
|  | 			type = "fixed", | ||||||
|  | 			fixed = { -0.5, -0.5,    -0.5,  0.5,    -0.4375, 0.5 }, | ||||||
|  | 		}, | ||||||
|  |  | ||||||
|  | 		on_place = function(itemstack, placer, pointed_thing) | ||||||
|  |  | ||||||
|  | 			local pitch = placer:get_look_pitch() | ||||||
|  | 			local above = pointed_thing.above | ||||||
|  | 			local under = pointed_thing.under | ||||||
|  | 			local node = minetest.env:get_node(above) | ||||||
|  | 			if node.name ~= "air" then return end | ||||||
|  |  | ||||||
|  | 			if above.x ~= under.x or above.z ~= under.z then  | ||||||
|  | 				local fdir = minetest.dir_to_facedir(placer:get_look_dir()) | ||||||
|  | 				minetest.env:add_node(above, {name = 'homedecor:'..m..'_table_small_square_s', param2 = fdir}) | ||||||
|  | 			elseif pitch > 0 then  | ||||||
|  | 				minetest.env:add_node(above, {name = 'homedecor:'..m..'_table_small_square_t'}) | ||||||
|  | 			else | ||||||
|  | 				minetest.env:add_node(above, {name = 'homedecor:'..m..'_table_small_square_b'}) | ||||||
|  | 			end | ||||||
|  | 			if not minetest.setting_getbool("creative_mode") then | ||||||
|  | 				itemstack:take_item() | ||||||
|  | 			end | ||||||
|  | 			return minetest.item_place_node(itemstack, placer, pointed_thing) | ||||||
|  | 		end | ||||||
|  | 	}) | ||||||
|  |  | ||||||
|  | 	minetest.register_node('homedecor:'..m..'_table_small_square_t', { | ||||||
|  | 		description = S(d.."Glass Table (Small, Square)"), | ||||||
|  | 		drawtype = 'nodebox', | ||||||
|  | 		tiles = { | ||||||
|  | 			'homedecor_'..m..'_table_small_square_tb.png', | ||||||
|  | 			'homedecor_'..m..'_table_small_square_tb.png', | ||||||
|  | 			'homedecor_'..m..'_table_small_square_edges.png', | ||||||
|  | 			'homedecor_'..m..'_table_small_square_edges.png', | ||||||
|  | 			'homedecor_'..m..'_table_small_square_edges.png', | ||||||
|  | 			'homedecor_'..m..'_table_small_square_edges.png' | ||||||
|  | 		}, | ||||||
|  | 		sunlight_propagates = true, | ||||||
|  | 		paramtype = 'light', | ||||||
|  | 		walkable = true, | ||||||
|  | 		groups = { snappy = 3, not_in_creative_inventory=1 }, | ||||||
|  | 		sounds = s, | ||||||
|  | 		paramtype2 = "facedir", | ||||||
|  |  | ||||||
|  | 		node_box = { | ||||||
|  | 			type = "fixed", | ||||||
|  | 			fixed = { | ||||||
|  | 				{ -0.4375, 0.4375, -0.5,     0.4375, 0.5, 0.5    }, | ||||||
|  | 				{ -0.5,    0.4375, -0.4375,  0.5,    0.5, 0.4375 } | ||||||
|  | 			}, | ||||||
|  | 		}, | ||||||
|  | 		selection_box = { | ||||||
|  | 			type = "fixed", | ||||||
|  | 			fixed = { -0.5,  0.4375, -0.5,  0.5, 0.5, 0.5 }, | ||||||
|  | 		}, | ||||||
|  | 		drop = 'homedecor:'..m..'_table_small_square_b' | ||||||
|  | 	}) | ||||||
|  |  | ||||||
|  | 	minetest.register_node('homedecor:'..m..'_table_small_square_s', { | ||||||
|  | 		description = S(d.." Table (Small, Square)"), | ||||||
|  | 		drawtype = 'nodebox', | ||||||
|  | 		tiles = { | ||||||
|  | 			'homedecor_'..m..'_table_small_square_tb.png', | ||||||
|  | 			'homedecor_'..m..'_table_small_square_tb.png', | ||||||
|  | 			'homedecor_'..m..'_table_small_square_edges.png', | ||||||
|  | 			'homedecor_'..m..'_table_small_square_edges.png', | ||||||
|  | 			'homedecor_'..m..'_table_small_square_edges.png', | ||||||
|  | 			'homedecor_'..m..'_table_small_square_edges.png' | ||||||
|  | 		}, | ||||||
|  | 		sunlight_propagates = true, | ||||||
|  | 		paramtype = 'light', | ||||||
|  | 		walkable = true, | ||||||
|  | 		groups = { snappy = 3, not_in_creative_inventory=1 }, | ||||||
|  | 		sounds = s, | ||||||
|  | 		paramtype2 = "facedir", | ||||||
|  |  | ||||||
|  | 		node_box = { | ||||||
|  | 			type = "fixed", | ||||||
|  | 			fixed = { | ||||||
|  | 				{ -0.4375, -0.5,    0.4375, 0.4375, 0.5,    0.5 }, | ||||||
|  | 				{ -0.5,    -0.4375, 0.4375, 0.5,    0.4375, 0.5 } | ||||||
|  | 			} | ||||||
|  | 		}, | ||||||
|  | 		selection_box = { | ||||||
|  | 			type = "fixed", | ||||||
|  | 			fixed = { -0.5, -0.5, 0.4375, 0.5, 0.5, 0.5 }, | ||||||
|  | 		}, | ||||||
|  | 		drop = 'homedecor:'..m..'_table_small_square_b' | ||||||
|  | 	}) | ||||||
|  |  | ||||||
|  | -- small round tables | ||||||
|  |  | ||||||
|  | 	minetest.register_node('homedecor:'..m..'_table_small_round_b', { | ||||||
|  | 		description = S(d.." Table (Small, Round)"), | ||||||
|  | 		drawtype = 'nodebox', | ||||||
|  | 		tiles = { | ||||||
|  | 			'homedecor_'..m..'_table_small_round_tb.png', | ||||||
|  | 			'homedecor_'..m..'_table_small_round_tb.png', | ||||||
|  | 			'homedecor_'..m..'_table_small_round_edges.png', | ||||||
|  | 			'homedecor_'..m..'_table_small_round_edges.png', | ||||||
|  | 			'homedecor_'..m..'_table_small_round_edges.png', | ||||||
|  | 			'homedecor_'..m..'_table_small_round_edges.png' | ||||||
|  | 		}, | ||||||
|  | 		wield_image = 'homedecor_'..m..'_table_small_round_tb.png', | ||||||
|  | 		inventory_image = 'homedecor_'..m..'_table_small_round_tb.png', | ||||||
|  | 		sunlight_propagates = true, | ||||||
|  | 		paramtype = 'light', | ||||||
|  | 		walkable = true, | ||||||
|  | 		groups = { snappy = 3 }, | ||||||
|  | 		sounds = s, | ||||||
|  | 		paramtype2 = "facedir", | ||||||
|  | 		node_box = { | ||||||
|  | 			type = "fixed", | ||||||
|  | 			fixed = { | ||||||
|  | 				{ -0.25,   -0.5, -0.5,    0.25,   -0.4375, 0.5    }, | ||||||
|  | 				{ -0.375,  -0.5, -0.4375, 0.375,  -0.4375, 0.4375 }, | ||||||
|  | 				{ -0.5,    -0.5, -0.25,   0.5,    -0.4375, 0.25   }, | ||||||
|  | 				{ -0.4375, -0.5, -0.375,  0.4375, -0.4375, 0.375  }, | ||||||
|  | 				{ -0.25,   -0.5, -0.5,    0.25,   -0.4375, 0.5    }, | ||||||
|  | 			} | ||||||
|  | 		}, | ||||||
|  | 		selection_box = { | ||||||
|  | 			type = "fixed", | ||||||
|  | 			fixed = { -0.5, -0.5, -0.5, 0.5, -0.4375, 0.5 }, | ||||||
|  | 		}, | ||||||
|  | 		on_place = function(itemstack, placer, pointed_thing) | ||||||
|  |  | ||||||
|  | 			local pitch = placer:get_look_pitch() | ||||||
|  | 			local above = pointed_thing.above | ||||||
|  | 			local under = pointed_thing.under | ||||||
|  |  | ||||||
|  | 			local node = minetest.env:get_node(above) | ||||||
|  | 			if node.name ~= "air" then return end | ||||||
|  |  | ||||||
|  | 			if above.x ~= under.x or above.z ~= under.z then  | ||||||
|  | 				local fdir = minetest.dir_to_facedir(placer:get_look_dir()) | ||||||
|  | 				minetest.env:add_node(above, {name = 'homedecor:'..m..'_table_small_round_s', param2 = fdir}) | ||||||
|  | 			elseif pitch > 0 then  | ||||||
|  | 				minetest.env:add_node(above, {name = 'homedecor:'..m..'_table_small_round_t'}) | ||||||
|  | 			else | ||||||
|  | 				minetest.env:add_node(above, {name = 'homedecor:'..m..'_table_small_round_b'}) | ||||||
|  | 			end | ||||||
|  | 			if not minetest.setting_getbool("creative_mode") then | ||||||
|  | 				itemstack:take_item() | ||||||
|  | 			end | ||||||
|  | 			return minetest.item_place_node(itemstack, placer, pointed_thing) | ||||||
|  | 		end | ||||||
|  | 	}) | ||||||
|  |  | ||||||
|  | 	minetest.register_node('homedecor:'..m..'_table_small_round_t', { | ||||||
|  | 		description = S(d.." Table (Small, Round)"), | ||||||
|  | 		drawtype = 'nodebox', | ||||||
|  | 		tiles = { | ||||||
|  | 			'homedecor_'..m..'_table_small_round_tb.png', | ||||||
|  | 			'homedecor_'..m..'_table_small_round_tb.png', | ||||||
|  | 			'homedecor_'..m..'_table_small_round_edges.png', | ||||||
|  | 			'homedecor_'..m..'_table_small_round_edges.png', | ||||||
|  | 			'homedecor_'..m..'_table_small_round_edges.png', | ||||||
|  | 			'homedecor_'..m..'_table_small_round_edges.png' | ||||||
|  | 		}, | ||||||
|  | 		sunlight_propagates = true, | ||||||
|  | 		paramtype = 'light', | ||||||
|  | 		walkable = true, | ||||||
|  | 		groups = { snappy = 3, not_in_creative_inventory=1 }, | ||||||
|  | 		sounds = s, | ||||||
|  | 		paramtype2 = "facedir", | ||||||
|  | 		node_box = { | ||||||
|  | 			type = "fixed", | ||||||
|  | 			fixed = { | ||||||
|  | 				{ -0.25,   0.4375, -0.5,    0.25,   0.5, 0.5    }, | ||||||
|  | 				{ -0.375,  0.4375, -0.4375, 0.375,  0.5, 0.4375 }, | ||||||
|  | 				{ -0.5,    0.4375, -0.25,   0.5,    0.5, 0.25   }, | ||||||
|  | 				{ -0.4375, 0.4375, -0.375,  0.4375, 0.5, 0.375  }, | ||||||
|  | 				{ -0.25,   0.4375, -0.5,    0.25,   0.5, 0.5    }, | ||||||
|  | 			} | ||||||
|  | 		}, | ||||||
|  | 		selection_box = { | ||||||
|  | 			type = "fixed", | ||||||
|  | 			fixed =    { -0.5, 0.4375, -0.5, 0.5, 0.5, 0.5 }, | ||||||
|  | 		}, | ||||||
|  | 		drop = 'homedecor:'..m..'_table_small_round_b' | ||||||
|  | 	}) | ||||||
|  |  | ||||||
|  | 	minetest.register_node('homedecor:'..m..'_table_small_round_s', { | ||||||
|  | 		description = S(d.." Table (Small, Round)"), | ||||||
|  | 		drawtype = 'nodebox', | ||||||
|  | 		tiles = { | ||||||
|  | 			'homedecor_'..m..'_table_small_round_edges.png', | ||||||
|  | 			'homedecor_'..m..'_table_small_round_edges.png', | ||||||
|  | 			'homedecor_'..m..'_table_small_round_edges.png', | ||||||
|  | 			'homedecor_'..m..'_table_small_round_edges.png', | ||||||
|  | 			'homedecor_'..m..'_table_small_round_tb.png', | ||||||
|  | 			'homedecor_'..m..'_table_small_round_tb.png', | ||||||
|  | 		}, | ||||||
|  | 		sunlight_propagates = true, | ||||||
|  | 		paramtype = 'light', | ||||||
|  | 		walkable = true, | ||||||
|  | 		groups = { snappy = 3, not_in_creative_inventory=1 }, | ||||||
|  | 		sounds = s, | ||||||
|  | 		paramtype2 = "facedir", | ||||||
|  | 		node_box = { | ||||||
|  | 			type = "fixed", | ||||||
|  | 			fixed = { | ||||||
|  | 				{ -0.25,   -0.5,    0.4375,  0.25,   0.5,    0.5 }, | ||||||
|  | 				{ -0.375,  -0.4375, 0.4375,  0.375,  0.4375, 0.5 }, | ||||||
|  | 				{ -0.5,    -0.25,   0.4375,  0.5,    0.25,   0.5 }, | ||||||
|  | 				{ -0.4375, -0.375,  0.4375,  0.4375, 0.375,  0.5 }, | ||||||
|  | 				{ -0.25,   -0.5,    0.4375,  0.25,   0.5,    0.5 }, | ||||||
|  | 			} | ||||||
|  | 		}, | ||||||
|  | 		selection_box = { | ||||||
|  | 			type = "fixed", | ||||||
|  | 			fixed =   { -0.5, -0.5, 0.4375, 0.5, 0.5, 0.5 }, | ||||||
|  | 		}, | ||||||
|  | 		drop = 'homedecor:'..m..'_table_small_round_b' | ||||||
|  | 	}) | ||||||
|  |  | ||||||
|  | -- Large square table pieces | ||||||
|  |  | ||||||
|  | 	minetest.register_node('homedecor:'..m..'_table_large_b', { | ||||||
|  | 		description = S(d.."Table Piece (large)"), | ||||||
|  | 		drawtype = 'nodebox', | ||||||
|  | 		tiles = {  | ||||||
|  | 			'homedecor_'..m..'_table_large_tb.png', | ||||||
|  | 			'homedecor_'..m..'_table_large_tb.png', | ||||||
|  | 			'homedecor_'..m..'_table_large_edges.png', | ||||||
|  | 			'homedecor_'..m..'_table_large_edges.png', | ||||||
|  | 			'homedecor_'..m..'_table_large_edges.png', | ||||||
|  | 			'homedecor_'..m..'_table_large_edges.png' | ||||||
|  | 		}, | ||||||
|  | 		wield_image = 'homedecor_'..m..'_table_large_tb.png', | ||||||
|  | 		inventory_image = 'homedecor_'..m..'_table_large_tb.png', | ||||||
|  | 		sunlight_propagates = true, | ||||||
|  | 		paramtype = 'light', | ||||||
|  | 		walkable = true, | ||||||
|  | 		groups = { snappy = 3 }, | ||||||
|  | 		sounds = s, | ||||||
|  | 		paramtype2 = "facedir", | ||||||
|  | 		node_box = { | ||||||
|  | 			type = "fixed", | ||||||
|  | 			fixed = { -0.5, -0.5, -0.5, 0.5, -0.4375, 0.5 }, | ||||||
|  | 		}, | ||||||
|  | 		selection_box = { | ||||||
|  | 			type = "fixed", | ||||||
|  | 			fixed = { -0.5, -0.5, -0.5, 0.5, -0.4375, 0.5 }, | ||||||
|  | 		}, | ||||||
|  | 		on_place = function(itemstack, placer, pointed_thing) | ||||||
|  |  | ||||||
|  | 			local pitch = placer:get_look_pitch() | ||||||
|  | 			local above = pointed_thing.above | ||||||
|  | 			local under = pointed_thing.under | ||||||
|  |  | ||||||
|  | 			local node = minetest.env:get_node(above) | ||||||
|  | 			if node.name ~= "air" then return end | ||||||
|  |  | ||||||
|  | 			if above.x ~= under.x or above.z ~= under.z then  | ||||||
|  | 				local fdir = minetest.dir_to_facedir(placer:get_look_dir()) | ||||||
|  | 				minetest.env:add_node(above, {name = 'homedecor:'..m..'_table_large_s', param2 = fdir}) | ||||||
|  | 			elseif pitch > 0 then  | ||||||
|  | 				minetest.env:add_node(above, {name = 'homedecor:'..m..'_table_large_t'}) | ||||||
|  | 			else | ||||||
|  | 				minetest.env:add_node(above, {name = 'homedecor:'..m..'_table_large_b'}) | ||||||
|  | 			end | ||||||
|  | 			if not minetest.setting_getbool("creative_mode") then | ||||||
|  | 				itemstack:take_item() | ||||||
|  | 			end | ||||||
|  | 			return minetest.item_place_node(itemstack, placer, pointed_thing) | ||||||
|  | 		end | ||||||
|  | 	}) | ||||||
|  |  | ||||||
|  | 	minetest.register_node('homedecor:'..m..'_table_large_t', { | ||||||
|  | 		description = S(d.."Table Piece (large)"), | ||||||
|  | 		drawtype = 'nodebox', | ||||||
|  | 		tiles = {  | ||||||
|  | 			'homedecor_'..m..'_table_large_tb.png', | ||||||
|  | 			'homedecor_'..m..'_table_large_tb.png', | ||||||
|  | 			'homedecor_'..m..'_table_large_edges.png', | ||||||
|  | 			'homedecor_'..m..'_table_large_edges.png', | ||||||
|  | 			'homedecor_'..m..'_table_large_edges.png', | ||||||
|  | 			'homedecor_'..m..'_table_large_edges.png' | ||||||
|  | 		}, | ||||||
|  | 		wield_image = 'homedecor_'..m..'_table_large_tb.png', | ||||||
|  | 		inventory_image = 'homedecor_'..m..'_table_large_tb.png', | ||||||
|  | 		sunlight_propagates = true, | ||||||
|  | 		paramtype = 'light', | ||||||
|  | 		walkable = true, | ||||||
|  | 		groups = { snappy = 3, not_in_creative_inventory=1 }, | ||||||
|  | 		sounds = s, | ||||||
|  | 		paramtype2 = "facedir", | ||||||
|  | 		node_box = { | ||||||
|  | 			type = "fixed", | ||||||
|  | 			fixed =    { -0.5, 0.4375, -0.5, 0.5, 0.5, 0.5 }, | ||||||
|  | 		}, | ||||||
|  | 		selection_box = { | ||||||
|  | 			type = "fixed", | ||||||
|  | 			fixed =    { -0.5, 0.4375, -0.5, 0.5, 0.5, 0.5 }, | ||||||
|  | 		}, | ||||||
|  | 	}) | ||||||
|  |  | ||||||
|  | 	minetest.register_node('homedecor:'..m..'_table_large_s', { | ||||||
|  | 		description = S(d.."Table Piece (large)"), | ||||||
|  | 		drawtype = 'nodebox', | ||||||
|  | 		tiles = {  | ||||||
|  | 			'homedecor_'..m..'_table_large_edges.png', | ||||||
|  | 			'homedecor_'..m..'_table_large_edges.png', | ||||||
|  | 			'homedecor_'..m..'_table_large_edges.png', | ||||||
|  | 			'homedecor_'..m..'_table_large_edges.png', | ||||||
|  | 			'homedecor_'..m..'_table_large_tb.png', | ||||||
|  | 			'homedecor_'..m..'_table_large_tb.png', | ||||||
|  | 		}, | ||||||
|  | 		wield_image = 'homedecor_'..m..'_table_large_tb.png', | ||||||
|  | 		inventory_image = 'homedecor_'..m..'_table_large_tb.png', | ||||||
|  | 		sunlight_propagates = true, | ||||||
|  | 		paramtype = 'light', | ||||||
|  | 		walkable = true, | ||||||
|  | 		groups = { snappy = 3, not_in_creative_inventory=1 }, | ||||||
|  | 		sounds = s, | ||||||
|  | 		paramtype2 = "facedir", | ||||||
|  | 		node_box = { | ||||||
|  | 			type = "fixed", | ||||||
|  | 			fixed =   { -0.5, -0.5, 0.4375, 0.5, 0.5, 0.5 }, | ||||||
|  | 		}, | ||||||
|  | 		selection_box = { | ||||||
|  | 			type = "fixed", | ||||||
|  | 			fixed =   { -0.5, -0.5, 0.4375, 0.5, 0.5, 0.5 }, | ||||||
|  | 		}, | ||||||
|  | 	}) | ||||||
|  |  | ||||||
|  | 	minetest.register_alias('homedecor:'..m..'_table_large', 'homedecor:'..m..'_table_large_b') | ||||||
|  | 	minetest.register_alias('homedecor:'..m..'_table_small_square', 'homedecor:'..m..'_table_small_square_b') | ||||||
|  | 	minetest.register_alias('homedecor:'..m..'_table_small_round', 'homedecor:'..m..'_table_small_round_b') | ||||||
|  |  | ||||||
|  | end | ||||||
|  |  | ||||||
| minetest.register_node('homedecor:utility_table_top', { | minetest.register_node('homedecor:utility_table_top', { | ||||||
| 	description = S("Utility Table"), | 	description = S("Utility Table"), | ||||||
| 	tiles = { 'homedecor_utility_table_top.png' }, | 	tiles = { | ||||||
| 	inventory_image = 'homedecor_utility_table_top.png', | 		'homedecor_utility_table_tb.png', | ||||||
| 	wield_image = 'homedecor_utility_table_top.png', | 		'homedecor_utility_table_tb.png', | ||||||
| 	drawtype = "signlike", | 		'homedecor_utility_table_edges.png', | ||||||
|  | 		'homedecor_utility_table_edges.png', | ||||||
|  | 		'homedecor_utility_table_edges.png', | ||||||
|  | 		'homedecor_utility_table_edges.png' | ||||||
|  | 	}, | ||||||
|  | 	wield_image = 'homedecor_utility_table_tb.png', | ||||||
|  | 	inventory_image = 'homedecor_utility_table_tb.png', | ||||||
|  | 	drawtype = "nodebox", | ||||||
| 	sunlight_propagates = false, | 	sunlight_propagates = false, | ||||||
| 	paramtype = "light", | 	paramtype = "light", | ||||||
| 	paramtype2 = "facedir", |  | ||||||
| 	walkable = true, | 	walkable = true, | ||||||
| 	groups = { snappy = 3 }, | 	groups = { snappy = 3 }, | ||||||
| 	sounds = default.node_sound_leaves_defaults(), | 	sounds = default.node_sound_wood_defaults(), | ||||||
| 	paramtype2 = "wallmounted", | 	paramtype2 = "wallmounted", | ||||||
| 	is_ground_content = true, | 	node_box = { | ||||||
|  | 		type = "wallmounted", | ||||||
|  | 		wall_bottom = { -0.5, -0.5,    -0.5,  0.5,   -0.4375, 0.5 }, | ||||||
|  | 		wall_top =    { -0.5,  0.4375, -0.5,  0.5,    0.5,    0.5 }, | ||||||
|  | 		wall_side =   { -0.5, -0.5,    -0.5, -0.4375, 0.5,    0.5 }, | ||||||
|  | 	}, | ||||||
|         selection_box = { |         selection_box = { | ||||||
| 			type = "wallmounted", | 		type = "wallmounted", | ||||||
|                          --wall_top = <default> | 		wall_bottom = { -0.5, -0.5,    -0.5,  0.5,   -0.4375, 0.5 }, | ||||||
|                          --wall_bottom = <default> | 		wall_top =    { -0.5,  0.4375, -0.5,  0.5,    0.5,    0.5 }, | ||||||
|                          --wall_side = <default> | 		wall_side =   { -0.5, -0.5,    -0.5, -0.4375, 0.5,    0.5 }, | ||||||
|                         }, | 	}, | ||||||
|  |  | ||||||
| }) |  | ||||||
|  |  | ||||||
| minetest.register_node('homedecor:wood_table_large', { |  | ||||||
| 	description = S("Wooden Tabletop piece"), |  | ||||||
| 	tiles = { 'homedecor_wood_table_large.png' }, |  | ||||||
| 	inventory_image = 'homedecor_wood_table_large.png', |  | ||||||
| 	wield_image = 'homedecor_wood_table_large.png', |  | ||||||
| 	drawtype = 'signlike', |  | ||||||
| 	sunlight_propagates = false, |  | ||||||
| 	paramtype = "light", |  | ||||||
| 	walkable = false, |  | ||||||
| 	groups = { snappy = 3 }, |  | ||||||
| 	sounds = default.node_sound_leaves_defaults(), |  | ||||||
| 	paramtype2 = "wallmounted", |  | ||||||
| 	is_ground_content = true, |  | ||||||
|         selection_box = { |  | ||||||
| 			type = "wallmounted", |  | ||||||
|                          --wall_top = <default> |  | ||||||
|                          --wall_bottom = <default> |  | ||||||
|                          --wall_side = <default> |  | ||||||
|                         }, |  | ||||||
| }) |  | ||||||
|  |  | ||||||
| minetest.register_node('homedecor:wood_table_small_round', { |  | ||||||
| 	description = S("Wooden Tabletop (Small, Round)"), |  | ||||||
| 	tiles = { 'homedecor_wood_table_small_round.png' }, |  | ||||||
| 	inventory_image = 'homedecor_wood_table_small_round.png', |  | ||||||
| 	wield_image = 'homedecor_wood_table_small_round.png', |  | ||||||
| 	drawtype = 'signlike', |  | ||||||
| 	sunlight_propagates = false, |  | ||||||
| 	paramtype = "light", |  | ||||||
| 	walkable = false, |  | ||||||
| 	groups = { snappy = 3 }, |  | ||||||
| 	sounds = default.node_sound_leaves_defaults(), |  | ||||||
| 	paramtype2 = "wallmounted", |  | ||||||
| 	is_ground_content = true, |  | ||||||
|         selection_box = { |  | ||||||
| 			type = "wallmounted", |  | ||||||
|                          --wall_top = <default> |  | ||||||
|                          --wall_bottom = <default> |  | ||||||
|                          --wall_side = <default> |  | ||||||
|                         }, |  | ||||||
| }) |  | ||||||
|  |  | ||||||
| minetest.register_node('homedecor:wood_table_small_square', { |  | ||||||
| 	description = S("Wooden Tabletop (Small, Square)"), |  | ||||||
| 	tiles = { 'homedecor_wood_table_small_square.png' }, |  | ||||||
| 	inventory_image = 'homedecor_wood_table_small_square.png', |  | ||||||
| 	wield_image = 'homedecor_wood_table_small_square.png', |  | ||||||
| 	drawtype = 'signlike', |  | ||||||
| 	sunlight_propagates = false, |  | ||||||
| 	paramtype = "light", |  | ||||||
| 	walkable = false, |  | ||||||
| 	groups = { snappy = 3 }, |  | ||||||
| 	sounds = default.node_sound_leaves_defaults(), |  | ||||||
| 	paramtype2 = "wallmounted", |  | ||||||
| 	is_ground_content = true, |  | ||||||
|         selection_box = { |  | ||||||
| 			type = "wallmounted", |  | ||||||
|                          --wall_top = <default> |  | ||||||
|                          --wall_bottom = <default> |  | ||||||
|                          --wall_side = <default> |  | ||||||
|                         }, |  | ||||||
| }) | }) | ||||||
|  |  | ||||||
| -- Various kinds of table legs | -- Various kinds of table legs | ||||||
| @@ -166,12 +431,15 @@ minetest.register_node("homedecor:table_legs_brass", { | |||||||
|         tiles = {"homedecor_table_legs_brass.png"}, |         tiles = {"homedecor_table_legs_brass.png"}, | ||||||
|         inventory_image = "homedecor_table_legs_brass.png", |         inventory_image = "homedecor_table_legs_brass.png", | ||||||
|         wield_image = "homedecor_table_legs_brass.png", |         wield_image = "homedecor_table_legs_brass.png", | ||||||
| 	visual_scale = 1.04, |  | ||||||
|         paramtype = "light", |         paramtype = "light", | ||||||
|         walkable = false, |         walkable = false, | ||||||
|         groups = {snappy=3}, |         groups = {snappy=3}, | ||||||
|         sounds = default.node_sound_leaves_defaults(), |         sounds = default.node_sound_leaves_defaults(), | ||||||
| 	walkable = true, | 	walkable = true, | ||||||
|  |         selection_box = { | ||||||
|  | 		type = "fixed", | ||||||
|  | 		fixed = { -0.37, -0.5, -0.37, 0.37, 0.5, 0.37 } | ||||||
|  | 	}, | ||||||
| }) | }) | ||||||
|  |  | ||||||
| minetest.register_node("homedecor:table_legs_wrought_iron", { | minetest.register_node("homedecor:table_legs_wrought_iron", { | ||||||
| @@ -180,12 +448,15 @@ minetest.register_node("homedecor:table_legs_wrought_iron", { | |||||||
|         tiles = {"homedecor_table_legs_wrought_iron.png"}, |         tiles = {"homedecor_table_legs_wrought_iron.png"}, | ||||||
|         inventory_image = "homedecor_table_legs_wrought_iron.png", |         inventory_image = "homedecor_table_legs_wrought_iron.png", | ||||||
|         wield_image = "homedecor_table_legs_wrought_iron.png", |         wield_image = "homedecor_table_legs_wrought_iron.png", | ||||||
| 	visual_scale = 1.04, |  | ||||||
|         paramtype = "light", |         paramtype = "light", | ||||||
|         walkable = false, |         walkable = false, | ||||||
|         groups = {snappy=3}, |         groups = {snappy=3}, | ||||||
|         sounds = default.node_sound_leaves_defaults(), |         sounds = default.node_sound_leaves_defaults(), | ||||||
| 	walkable = true, | 	walkable = true, | ||||||
|  |         selection_box = { | ||||||
|  | 		type = "fixed", | ||||||
|  | 		fixed = { -0.37, -0.5, -0.37, 0.37, 0.5, 0.37 } | ||||||
|  | 	}, | ||||||
| }) | }) | ||||||
|  |  | ||||||
| minetest.register_node('homedecor:utility_table_legs', { | minetest.register_node('homedecor:utility_table_legs', { | ||||||
| @@ -194,11 +465,14 @@ minetest.register_node('homedecor:utility_table_legs', { | |||||||
| 	tiles = { 'homedecor_utility_table_legs.png' }, | 	tiles = { 'homedecor_utility_table_legs.png' }, | ||||||
| 	inventory_image = 'homedecor_utility_table_legs_inv.png', | 	inventory_image = 'homedecor_utility_table_legs_inv.png', | ||||||
| 	wield_image = 'homedecor_utility_table_legs.png', | 	wield_image = 'homedecor_utility_table_legs.png', | ||||||
| 	visual_scale = 1.04, |  | ||||||
| 	sunlight_propagates = true, | 	sunlight_propagates = true, | ||||||
| 	paramtype = "light", | 	paramtype = "light", | ||||||
| 	walkable = false, | 	walkable = false, | ||||||
| 	groups = { snappy = 3 }, | 	groups = { snappy = 3 }, | ||||||
| 	sounds = default.node_sound_leaves_defaults(), | 	sounds = default.node_sound_wood_defaults(), | ||||||
|  |         selection_box = { | ||||||
|  | 		type = "fixed", | ||||||
|  | 		fixed = { -0.37, -0.5, -0.37, 0.37, 0.5, 0.37 } | ||||||
|  | 	}, | ||||||
| }) | }) | ||||||
|  |  | ||||||
|   | |||||||
							
								
								
									
										
											BIN
										
									
								
								textures/homedecor_glass_table_large_edges.png
									
									
									
									
									
										Normal file
									
								
							
							
						
						| After Width: | Height: | Size: 413 B | 
| Before Width: | Height: | Size: 201 B After Width: | Height: | Size: 201 B | 
							
								
								
									
										
											BIN
										
									
								
								textures/homedecor_glass_table_small_round_edges.png
									
									
									
									
									
										Normal file
									
								
							
							
						
						| After Width: | Height: | Size: 413 B | 
| Before Width: | Height: | Size: 226 B After Width: | Height: | Size: 226 B | 
| Before Width: | Height: | Size: 213 B | 
							
								
								
									
										
											BIN
										
									
								
								textures/homedecor_glass_table_small_square_edges.png
									
									
									
									
									
										Normal file
									
								
							
							
						
						| After Width: | Height: | Size: 413 B | 
							
								
								
									
										
											BIN
										
									
								
								textures/homedecor_glass_table_small_square_tb.png
									
									
									
									
									
										Normal file
									
								
							
							
						
						| After Width: | Height: | Size: 236 B | 
							
								
								
									
										
											BIN
										
									
								
								textures/homedecor_utility_table_edges.png
									
									
									
									
									
										Normal file
									
								
							
							
						
						| After Width: | Height: | Size: 3.1 KiB | 
| Before Width: | Height: | Size: 3.2 KiB After Width: | Height: | Size: 3.2 KiB | 
							
								
								
									
										
											BIN
										
									
								
								textures/homedecor_wood_table_large_edges.png
									
									
									
									
									
										Normal file
									
								
							
							
						
						| After Width: | Height: | Size: 3.1 KiB | 
| Before Width: | Height: | Size: 3.2 KiB After Width: | Height: | Size: 3.2 KiB | 
							
								
								
									
										
											BIN
										
									
								
								textures/homedecor_wood_table_small_round_edges.png
									
									
									
									
									
										Normal file
									
								
							
							
						
						| After Width: | Height: | Size: 3.1 KiB | 
| Before Width: | Height: | Size: 3.3 KiB After Width: | Height: | Size: 3.3 KiB | 
							
								
								
									
										
											BIN
										
									
								
								textures/homedecor_wood_table_small_square_edges.png
									
									
									
									
									
										Normal file
									
								
							
							
						
						| After Width: | Height: | Size: 3.1 KiB | 
| Before Width: | Height: | Size: 3.3 KiB After Width: | Height: | Size: 3.3 KiB |