From e3a6ed9ddbd63adde650a39cd39d1ed48ee665db Mon Sep 17 00:00:00 2001 From: unknown <24964441+wsor4035@users.noreply.github.com> Date: Mon, 11 Apr 2022 00:03:37 -0400 Subject: [PATCH] add hd inbox --- homedecor_inbox/.luacheckrc | 20 -------------------- homedecor_inbox/init.lua | 22 ++++++++++++---------- homedecor_inbox/mod.conf | 2 +- 3 files changed, 13 insertions(+), 31 deletions(-) delete mode 100644 homedecor_inbox/.luacheckrc diff --git a/homedecor_inbox/.luacheckrc b/homedecor_inbox/.luacheckrc deleted file mode 100644 index 0a057505..00000000 --- a/homedecor_inbox/.luacheckrc +++ /dev/null @@ -1,20 +0,0 @@ -unused_args = false -allow_defined_top = true -max_comment_line_length = 999 - -read_globals = { - "DIR_DELIM", - "minetest", "core", - "unpack", - "dump", - table = { fields = { "copy", "getn" } }, - "vector", "nodeupdate", - "VoxelManip", "VoxelArea", - "PseudoRandom", "ItemStack", - "default", - "screwdriver", "homedecor", -} - -globals = { -} - diff --git a/homedecor_inbox/init.lua b/homedecor_inbox/init.lua index 1701dc51..6d870dc4 100644 --- a/homedecor_inbox/init.lua +++ b/homedecor_inbox/init.lua @@ -2,15 +2,6 @@ local S = minetest.get_translator("inbox") local inbox = {} -minetest.register_craft({ - output ="homedecor:inbox", - recipe = { - {"","default:steel_ingot",""}, - {"default:steel_ingot","","default:steel_ingot"}, - {"default:steel_ingot","default:steel_ingot","default:steel_ingot"} - } -}) - local mb_cbox = { type = "fixed", fixed = { -5/16, -8/16, -8/16, 5/16, 2/16, 8/16 } @@ -31,7 +22,9 @@ homedecor.register("inbox", { collision_box = mb_cbox, paramtype2 = "facedir", groups = {choppy=2,oddly_breakable_by_hand=2}, - sounds = default.node_sound_wood_defaults(), + _sound_def = { + key = "node_sound_wood_defaults", + }, on_rotate = minetest.get_modpath("screwdriver") and screwdriver.rotate_simple or nil, after_place_node = function(pos, placer, itemstack) local meta = minetest.get_meta(pos) @@ -103,6 +96,15 @@ homedecor.register("inbox", { allow_metadata_inventory_move = function(pos) return 0 end, + crafts = { + { + recipe = { + {"","steel_ingot",""}, + {"steel_ingot","","steel_ingot"}, + {"steel_ingot","steel_ingot","steel_ingot"} + } + } + } }) minetest.register_alias("inbox:empty", "homedecor:inbox") diff --git a/homedecor_inbox/mod.conf b/homedecor_inbox/mod.conf index d6a2322d..9ba7cca6 100644 --- a/homedecor_inbox/mod.conf +++ b/homedecor_inbox/mod.conf @@ -1,3 +1,3 @@ name = homedecor_inbox -depends = default, homedecor_common +depends = homedecor_common optional_depends = screwdriver