Make switching station run all machines it is connected to, including those in unloaded blocks.

This commit is contained in:
Novatux
2014-07-11 11:00:46 +02:00
parent 871ded6e6a
commit 563a4c071d
18 changed files with 839 additions and 848 deletions

View File

@ -59,7 +59,6 @@ function technic.register_cable(tier, size)
end
end
minetest.register_on_placenode(function(pos, node)
for tier, machine_list in pairs(technic.machines) do
if machine_list[node.name] ~= nil then
@ -79,7 +78,6 @@ minetest.register_on_dignode(function(pos, node)
end
end)
function technic.get_cable_id(links)
return (links[6] * 1) + (links[5] * 2)
+ (links[4] * 4) + (links[3] * 8)
@ -146,7 +144,7 @@ function technic.gen_cable_nodebox(x1, y1, z1, x2, y2, z2, size)
local box_center = {-size, -size, -size, size, size, size}
local box_y1 = {-size, -size, -size, size, 0.5, size} -- y+
local box_x1 = {-size, -size, -size, 0.5, size, size} -- x+
local box_z1 = {-size, -size, size, size, size, 0.5} -- z+
local box_z1 = {-size, -size, size, size, size, 0.5} -- z+
local box_z2 = {-size, -size, -0.5, size, size, size} -- z-
local box_y2 = {-size, -0.5, -size, size, size, size} -- y-
local box_x2 = {-0.5, -size, -size, size, size, size} -- x-