Warehouse boxes bugfix for the Blackhole bugfix

This commit is contained in:
Joachim Stolberg 2019-03-23 19:30:59 +01:00
parent dc71bf90f4
commit a2926e724c
4 changed files with 5 additions and 3 deletions

@ -130,7 +130,7 @@ tubelib.register_node(NODE_NAME,
{NODE_NAME.."_active", NODE_NAME.."_defect"}, { {NODE_NAME.."_active", NODE_NAME.."_defect"}, {
on_push_item = function(pos, side, item) on_push_item = function(pos, side, item)
local meta = M(pos) local meta = M(pos)
meta:set_string("push_dir", side) meta:set_string("push_dir", wh.Turn180[side])
local num = wh.numbers_to_shift(Box, meta, item) local num = wh.numbers_to_shift(Box, meta, item)
if num > 0 then if num > 0 then
item:set_count(num) item:set_count(num)

@ -130,7 +130,7 @@ tubelib.register_node(NODE_NAME,
{NODE_NAME.."_active", NODE_NAME.."_defect"}, { {NODE_NAME.."_active", NODE_NAME.."_defect"}, {
on_push_item = function(pos, side, item) on_push_item = function(pos, side, item)
local meta = M(pos) local meta = M(pos)
meta:set_string("push_dir", side) meta:set_string("push_dir", wh.Turn180[side])
local num = wh.numbers_to_shift(Box, meta, item) local num = wh.numbers_to_shift(Box, meta, item)
if num > 0 then if num > 0 then
item:set_count(num) item:set_count(num)

@ -130,7 +130,7 @@ tubelib.register_node(NODE_NAME,
{NODE_NAME.."_active", NODE_NAME.."_defect"}, { {NODE_NAME.."_active", NODE_NAME.."_defect"}, {
on_push_item = function(pos, side, item) on_push_item = function(pos, side, item)
local meta = M(pos) local meta = M(pos)
meta:set_string("push_dir", side) meta:set_string("push_dir", wh.Turn180[side])
local num = wh.numbers_to_shift(Box, meta, item) local num = wh.numbers_to_shift(Box, meta, item)
if num > 0 then if num > 0 then
item:set_count(num) item:set_count(num)

@ -21,9 +21,11 @@ local STANDBY_TICKS = 4
local COUNTDOWN_TICKS = 2 local COUNTDOWN_TICKS = 2
local CYCLE_TIME = 2 local CYCLE_TIME = 2
local Cache = {} local Cache = {}
techpack_warehouse.Box = {} techpack_warehouse.Box = {}
techpack_warehouse.Turn180 = {F="B", L="R", B="F", R="L", U="D", D="U"}
local function formspec(self, pos, meta) local function formspec(self, pos, meta)
return "size[10,9]".. return "size[10,9]"..