summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorHybridDog <ovvv@web.de>2015-11-18 10:07:00 +0100
committerHybridDog <ovvv@web.de>2015-11-18 10:07:00 +0100
commit6de437b83d99cdc49dc7899b3bf4fc6f94054d92 (patch)
tree47a82607eb563973f613048c98a9ff2a8e69df4e
parent352e23cfb12c00b89e4d2b382b7821555203ae4c (diff)
downloadpipeworks-6de437b83d99cdc49dc7899b3bf4fc6f94054d92.tar
pipeworks-6de437b83d99cdc49dc7899b3bf4fc6f94054d92.tar.gz
pipeworks-6de437b83d99cdc49dc7899b3bf4fc6f94054d92.tar.bz2
pipeworks-6de437b83d99cdc49dc7899b3bf4fc6f94054d92.tar.xz
pipeworks-6de437b83d99cdc49dc7899b3bf4fc6f94054d92.zip
fix 2 other minetest.item_drops
-rw-r--r--autocrafter.lua20
-rw-r--r--sorting_tubes.lua2
2 files changed, 11 insertions, 11 deletions
diff --git a/autocrafter.lua b/autocrafter.lua
index 3609068..6d00a7c 100644
--- a/autocrafter.lua
+++ b/autocrafter.lua
@@ -223,7 +223,7 @@ local function upgrade_autocrafter(pos, meta)
if not recipe then return end
for idx, stack in ipairs(recipe) do
if not stack:is_empty() then
- minetest.item_drop(stack, "", pos)
+ minetest.item_drop(stack, nil, pos)
stack:set_count(1)
stack:set_wear(0)
inv:set_stack("recipe", idx, stack)
@@ -238,24 +238,24 @@ local function upgrade_autocrafter(pos, meta)
end
minetest.register_node("pipeworks:autocrafter", {
- description = "Autocrafter",
- drawtype = "normal",
- tiles = {"pipeworks_autocrafter.png"},
- groups = {snappy = 3, tubedevice = 1, tubedevice_receiver = 1},
+ description = "Autocrafter",
+ drawtype = "normal",
+ tiles = {"pipeworks_autocrafter.png"},
+ groups = {snappy = 3, tubedevice = 1, tubedevice_receiver = 1},
tube = {insert_object = function(pos, node, stack, direction)
local meta = minetest.get_meta(pos)
local inv = meta:get_inventory()
local added = inv:add_item("src", stack)
after_inventory_change(pos)
return added
- end,
+ end,
can_insert = function(pos, node, stack, direction)
local meta = minetest.get_meta(pos)
local inv = meta:get_inventory()
return inv:room_for_item("src", stack)
- end,
- input_inventory = "dst",
- connect_sides = {left = 1, right = 1, front = 1, back = 1, top = 1, bottom = 1}},
+ end,
+ input_inventory = "dst",
+ connect_sides = {left = 1, right = 1, front = 1, back = 1, top = 1, bottom = 1}},
on_construct = function(pos)
local meta = minetest.get_meta(pos)
local inv = meta:get_inventory()
@@ -282,7 +282,7 @@ minetest.register_node("pipeworks:autocrafter", {
local meta = minetest.get_meta(pos)
local inv = meta:get_inventory()
return (inv:is_empty("src") and inv:is_empty("dst"))
- end,
+ end,
after_place_node = pipeworks.scan_for_tube_objects,
after_dig_node = function(pos)
pipeworks.scan_for_tube_objects(pos)
diff --git a/sorting_tubes.lua b/sorting_tubes.lua
index 6f47f72..795291b 100644
--- a/sorting_tubes.lua
+++ b/sorting_tubes.lua
@@ -6,7 +6,7 @@ if pipeworks.enable_mese_tube then
local inv = meta:get_inventory()
for i = 1, 6 do
for _, stack in ipairs(inv:get_list("line"..i)) do
- minetest.item_drop(stack, "", pos)
+ minetest.item_drop(stack, nil, pos)
end
end
end