Skip to content

Commit 8e87671

Browse files
committed
Fix bare pistons pushing objects into walls
1 parent fe649e8 commit 8e87671

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

mesecons_mvps/init.lua

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -364,7 +364,7 @@ function mesecon.mvps_move_objects(pos, dir, nodestack, movefactor)
364364
local min_pos = vector.offset(obj_pos, cbox[1] + 0.01, cbox[2] + 0.01, cbox[3] + 0.01)
365365
local max_pos = vector.offset(obj_pos, cbox[4] - 0.01, cbox[5] - 0.01, cbox[6] - 0.01)
366366
if not area_intersects_nodes(vector.add(min_pos, dir), vector.add(max_pos, dir)) or
367-
area_intersects_nodes(min_pos, max_pos, moved_positions) then
367+
(nodestack[1] ~= nil and area_intersects_nodes(min_pos, max_pos, moved_positions)) then
368368
obj:move_to(vector.add(obj_pos, dir))
369369
end
370370
end

0 commit comments

Comments
 (0)