1
0
mirror of https://github.com/sys4-fr/server-nalc.git synced 2024-11-19 16:50:31 +01:00

Updated homedecor, and fixed cloud pedestals

This commit is contained in:
LeMagnesium 2015-02-24 18:23:14 +01:00
parent 70b36257ea
commit bcd0118ba9
56 changed files with 96 additions and 31 deletions

View File

@ -11,4 +11,6 @@ Licenses:
http://freesound.org/people/j1987/sounds/106116/
* For the doorbell sound, CC0 by guitarguy1985 on freesound.org
http://freesound.org/people/guitarguy1985/sounds/69384/
* For the book sound, Public Domain by mckinneysound's on http://www.freesfx.co.uk/
http://www.freesfx.co.uk/sfx/book?p=3
* For all images and everything else, WTFPL.

View File

@ -2982,6 +2982,34 @@ minetest.register_craft({
},
})
local picture_dyes = {
{"dye:brown", "dye:green"}, -- the figure sitting by the tree, wielding a pick
{"dye:green", "dye:blue"} -- the "family photo"
}
for i in ipairs(picture_dyes) do
minetest.register_craft({
output = "homedecor:picture_frame"..i,
recipe = {
{ picture_dyes[i][1], picture_dyes[i][2] },
{ "homedecor:blank_canvas", "group:stick" },
},
})
end
local dlamp_colors = { "red","blue","green","violet" }
for _, color in ipairs(dlamp_colors) do
minetest.register_craft({
output = "homedecor:desk_lamp_"..color,
recipe = {
{ "", "homedecor:steel_strip", "homedecor:glowlight_small_cube_white" },
{ "", "homedecor:copper_wire", "" },
{ "homedecor:plastic_sheeting", "dye:"..color, "homedecor:plastic_sheeting" },
},
})
end
if (minetest.get_modpath("technic") and minetest.get_modpath("dye") and minetest.get_modpath("bees")) then
technic.register_separating_recipe({ input = {"bees:wax 1"}, output = {"homedecor:oil_extract 2","dye:yellow 1"} })
end

View File

@ -391,3 +391,23 @@ for _, color in ipairs(lamp_colors) do
reg_lamp("hi", "max", "h", 11, color )
reg_lamp("max", "off", "x", 14, color )
end
local dlamp_cbox = {
type = "fixed",
fixed = { -0.2, -0.5, -0.15, 0.32, 0.12, 0.15 },
}
local dlamp_colors = { "red","blue","green","violet" }
for _, color in ipairs(dlamp_colors) do
homedecor.register("desk_lamp_"..color, {
description = S("Desk Lamp ("..color..")"),
mesh = "homedecor_desk_lamp.obj",
tiles = {"homedecor_desk_lamp_"..color..".png"},
inventory_image = "homedecor_desk_lamp_inv_"..color..".png",
wield_image = "homedecor_desk_lamp_inv_"..color..".png",
selection_box = dlamp_cbox,
collision_box = dlamp_cbox,
groups = {snappy=3},
})
end

View File

@ -1244,24 +1244,12 @@ for c in ipairs(bookcolors) do
homedecor.register("book_"..color, {
description = S("Book (%s)"):format(color_d),
tiles = {
"homedecor_book_"..color.."_top.png",
"homedecor_book_"..color.."_bottom.png",
"homedecor_book_open_sides.png",
"homedecor_book_"..color.."_bottom.png",
"homedecor_book_open_sides.png",
"homedecor_book_open_sides.png"
},
mesh = "homedecor_book.obj",
tiles = { "homedecor_book_"..color..".png" },
inventory_image = "homedecor_book_"..color.."_inv.png",
wield_image = "homedecor_book_"..color.."_inv.png",
groups = { snappy=3, oddly_breakable_by_hand=3, book=1 },
stack_max = 1,
node_box = {
type = "fixed",
fixed = {
{0, -0.5, -0.375, 0.3125, -0.4375, 0.0625},
}
},
on_rightclick = function(pos, node, clicker)
local fdir = node.param2
minetest.swap_node(pos, { name = "homedecor:book_open_"..color, param2 = fdir })
@ -1321,30 +1309,39 @@ homedecor.register("book_"..color, {
end
minetest.show_formspec(user:get_player_name(), BOOK_FORMNAME, formspec)
end,
selection_box = {
type = "fixed",
fixed = {-0.2, -0.5, -0.25, 0.2, -0.35, 0.25}
},
collision_box = {
type = "fixed",
fixed = {-0.15, -0.5, -0.25, 0.15, -0.35, 0.25}
},
})
homedecor.register("book_open_"..color, {
tiles = {
"homedecor_book_open_top.png",
"homedecor_book_open_"..color.."_bottom.png",
"homedecor_book_open_sides.png",
"homedecor_book_open_sides.png",
"homedecor_book_open_sides.png",
"homedecor_book_open_sides.png"
},
mesh = "homedecor_book_open.obj",
tiles = { "homedecor_book_open_"..color..".png" },
groups = { snappy=3, oddly_breakable_by_hand=3, not_in_creative_inventory=1 },
node_box = {
type = "fixed",
fixed = {
{-0.3125, -0.5, -0.375, 0.3125, -0.47, 0.0625}, -- NodeBox1
}
},
drop = "homedecor:book_"..color,
on_dig = book_dig,
on_rightclick = function(pos, node, clicker)
local fdir = node.param2
minetest.swap_node(pos, { name = "homedecor:book_"..color, param2 = fdir })
minetest.sound_play("homedecor_book_close", {
pos=pos,
max_hear_distance = 3,
gain = 2,
})
end,
selection_box = {
type = "fixed",
fixed = {-0.35, -0.5, -0.25, 0.35, -0.4, 0.25}
},
collision_box = {
type = "fixed",
fixed = {-0.35, -0.5, -0.25, 0.35, -0.4, 0.25}
},
})
end
@ -1362,6 +1359,8 @@ minetest.register_on_player_receive_fields(function(player, form_name, fields)
fields.title, fields.text, player:get_player_name()
stack:set_metadata(minetest.serialize(data))
player:set_wielded_item(stack)
minetest.log("action", player:get_player_name().." has written in a book (title: \""..fields.title.."\"): \""..fields.text..
"\" at location: "..minetest.pos_to_string(player:getpos()))
end)
homedecor.register("calendar", {
@ -1409,3 +1408,21 @@ homedecor.register("wine_rack", {
sounds = default.node_sound_defaults(),
})
local pframe_cbox = {
type = "fixed",
fixed = { -0.18, -0.5, -0.08, 0.18, -0.08, 0.18 }
}
local n = { 1, 2 }
for _, i in ipairs(n) do
homedecor.register("picture_frame"..i, {
description = S("Picture Frame"),
mesh = "homedecor_picture_frame.obj",
tiles = { "homedecor_picture_frame"..i..".png" },
inventory_image = "homedecor_picture_frame"..i.."_inv.png",
wield_image = "homedecor_picture_frame"..i.."_inv.png",
groups = {snappy = 3},
selection_box = pframe_cbox,
collision_box = pframe_cbox,
})
end

Binary file not shown.

After

Width:  |  Height:  |  Size: 154 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 91 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 196 B

After

Width:  |  Height:  |  Size: 2.0 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 263 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 154 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 93 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 196 B

After

Width:  |  Height:  |  Size: 1.9 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 248 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 154 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 164 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 196 B

After

Width:  |  Height:  |  Size: 1.7 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 250 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 154 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 93 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 196 B

After

Width:  |  Height:  |  Size: 1.6 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 253 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 300 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 82 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 300 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 74 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 300 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 82 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 300 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 72 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 344 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 82 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 72 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 9.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 300 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 74 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 154 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 164 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 196 B

After

Width:  |  Height:  |  Size: 2.0 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 223 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 154 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 93 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 196 B

After

Width:  |  Height:  |  Size: 1.8 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 247 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 217 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 217 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 531 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.0 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 217 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 217 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.7 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.5 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.6 KiB

View File

@ -1,6 +1,4 @@
-- See README.txt for licensing and other information
local tmp = {}
itemframes = {}
minetest.register_entity("itemframes:item",{
hp_max = 1,
@ -223,7 +221,7 @@ itemframes.register_pedestal("obsidian", "default:obsidian",
default.node_sound_stone_defaults()
)
itemframes.register_pedestal("cloud", "default:cloud",
{cracky=3,not_in_creative_inventory=1,pedestal=1},
{cracky=1,level=2,not_in_creative_inventory=1,pedestal=1},
{"default_cloud.png"},
"Cloud Pedestal",
default.node_sound_defaults()