diff options
author | DS <vorunbekannt75@web.de> | 2017-08-17 21:20:38 +0200 |
---|---|---|
committer | Vanessa Ezekowitz <vanessaezekowitz@gmail.com> | 2017-08-17 15:20:38 -0400 |
commit | c57a35d5bd5110f0de811c2a9871acf71db72060 (patch) | |
tree | 9b83f5eef563859dc6df0f94416cccebf700cabd | |
parent | f9f436fd7e789a513288a298123f34b7cfd03504 (diff) | |
download | pipeworks-c57a35d5bd5110f0de811c2a9871acf71db72060.tar pipeworks-c57a35d5bd5110f0de811c2a9871acf71db72060.tar.gz pipeworks-c57a35d5bd5110f0de811c2a9871acf71db72060.tar.bz2 pipeworks-c57a35d5bd5110f0de811c2a9871acf71db72060.tar.xz pipeworks-c57a35d5bd5110f0de811c2a9871acf71db72060.zip |
filter: allow to take items out of locked chests if same owner (#193)
-rw-r--r-- | compat-chests.lua | 13 |
1 files changed, 7 insertions, 6 deletions
diff --git a/compat-chests.lua b/compat-chests.lua index 7cff6fd..69eb2f1 100644 --- a/compat-chests.lua +++ b/compat-chests.lua @@ -36,7 +36,7 @@ local function get_chest_formspec(pos) pipeworks.button_on } )..pipeworks.button_label - + return formspec end @@ -62,7 +62,7 @@ minetest.register_on_player_receive_fields(function(player, formname, fields) local sound = open_chests[pn].sound local swap = open_chests[pn].swap local node = minetest.get_node(pos) - + open_chests[pn] = nil for k, v in pairs(open_chests) do if v.pos.x == pos.x and v.pos.y == pos.y and v.pos.z == pos.z then @@ -71,13 +71,13 @@ minetest.register_on_player_receive_fields(function(player, formname, fields) end minetest.after(0.2, function() minetest.swap_node(pos, { name = "default:" .. swap, param2 = node.param2 }) - + -- Pipeworks notification pipeworks.after_place(pos) end) minetest.sound_play(sound, {gain = 0.3, pos = pos, max_hear_distance = 10}) end - + -- Pipeworks Switch if pipeworks.may_configure(pos, player) and not fields.quit then fs_helpers.on_receive_fields(pos, fields) @@ -142,6 +142,7 @@ override_protected = { end return inv:room_for_item("main", stack) end, + input_inventory = "main", connect_sides = {left = 1, right = 1, back = 1, bottom = 1, top = 1} }, after_dig_node = pipeworks.after_dig @@ -191,9 +192,9 @@ override = { after_dig_node = pipeworks.after_dig } --[[local override_common = { - + } -for k,v in pairs(override_common) do +for k,v in pairs(override_common) do override_protected[k] = v override[k] = v end]] |