forked from mtcontrib/pipeworks
rules_all has to be global. made it so, confined to pipeworks.{} table
This commit is contained in:
parent
3e02d5104a
commit
bdbdab0dfd
|
@ -172,7 +172,7 @@ minetest.register_node("pipeworks:deployer_off", {
|
||||||
description = "Deployer",
|
description = "Deployer",
|
||||||
tile_images = {"pipeworks_deployer_top.png","pipeworks_deployer_bottom.png","pipeworks_deployer_side2.png","pipeworks_deployer_side1.png",
|
tile_images = {"pipeworks_deployer_top.png","pipeworks_deployer_bottom.png","pipeworks_deployer_side2.png","pipeworks_deployer_side1.png",
|
||||||
"pipeworks_deployer_back.png","pipeworks_deployer_front_off.png"},
|
"pipeworks_deployer_back.png","pipeworks_deployer_front_off.png"},
|
||||||
mesecons = {effector={rules=rules_all,action_on=deployer_on,action_off=deployer_off}},
|
mesecons = {effector={rules=pipeworks.rules_all,action_on=deployer_on,action_off=deployer_off}},
|
||||||
tube={insert_object=function(pos,node,stack,direction)
|
tube={insert_object=function(pos,node,stack,direction)
|
||||||
local meta=minetest.get_meta(pos)
|
local meta=minetest.get_meta(pos)
|
||||||
local inv=meta:get_inventory()
|
local inv=meta:get_inventory()
|
||||||
|
@ -232,7 +232,7 @@ minetest.register_node("pipeworks:deployer_on", {
|
||||||
description = "Deployer",
|
description = "Deployer",
|
||||||
tile_images = {"pipeworks_deployer_top.png","pipeworks_deployer_bottom.png","pipeworks_deployer_side2.png","pipeworks_deployer_side1.png",
|
tile_images = {"pipeworks_deployer_top.png","pipeworks_deployer_bottom.png","pipeworks_deployer_side2.png","pipeworks_deployer_side1.png",
|
||||||
"pipeworks_deployer_back.png","pipeworks_deployer_front_on.png"},
|
"pipeworks_deployer_back.png","pipeworks_deployer_front_on.png"},
|
||||||
mesecons = {effector={rules=rules_all,action_on=deployer_on,action_off=deployer_off}},
|
mesecons = {effector={rules=pipeworks.rules_all,action_on=deployer_on,action_off=deployer_off}},
|
||||||
tube={insert_object=function(pos,node,stack,direction)
|
tube={insert_object=function(pos,node,stack,direction)
|
||||||
local meta=minetest.get_meta(pos)
|
local meta=minetest.get_meta(pos)
|
||||||
local inv=meta:get_inventory()
|
local inv=meta:get_inventory()
|
||||||
|
|
2
init.lua
2
init.lua
|
@ -107,7 +107,7 @@ dofile(pipeworks.modpath.."/flowing_logic.lua")
|
||||||
dofile(pipeworks.modpath.."/crafts.lua")
|
dofile(pipeworks.modpath.."/crafts.lua")
|
||||||
dofile(pipeworks.modpath.."/tubes.lua")
|
dofile(pipeworks.modpath.."/tubes.lua")
|
||||||
|
|
||||||
local rules_all = {{x=0, y=0, z=1},{x=0, y=0, z=-1},{x=1, y=0, z=0},{x=-1, y=0, z=0},
|
pipeworks.rules_all = {{x=0, y=0, z=1},{x=0, y=0, z=-1},{x=1, y=0, z=0},{x=-1, y=0, z=0},
|
||||||
{x=0, y=1, z=1},{x=0, y=1, z=-1},{x=1, y=1, z=0},{x=-1, y=1, z=0},
|
{x=0, y=1, z=1},{x=0, y=1, z=-1},{x=1, y=1, z=0},{x=-1, y=1, z=0},
|
||||||
{x=0, y=-1, z=1},{x=0, y=-1, z=-1},{x=1, y=-1, z=0},{x=-1, y=-1, z=0},
|
{x=0, y=-1, z=1},{x=0, y=-1, z=-1},{x=1, y=-1, z=0},{x=-1, y=-1, z=0},
|
||||||
{x=0, y=1, z=0}, {x=0, y=-1, z=0}}
|
{x=0, y=1, z=0}, {x=0, y=-1, z=0}}
|
||||||
|
|
|
@ -209,7 +209,7 @@ minetest.register_node("pipeworks:nodebreaker_off", {
|
||||||
is_ground_content = true,
|
is_ground_content = true,
|
||||||
paramtype2 = "facedir",
|
paramtype2 = "facedir",
|
||||||
groups = {snappy=2,choppy=2,oddly_breakable_by_hand=2, mesecon = 2,tubedevice=1},
|
groups = {snappy=2,choppy=2,oddly_breakable_by_hand=2, mesecon = 2,tubedevice=1},
|
||||||
mesecons= {effector={rules=rules_all,action_on=node_breaker_on, action_off=node_breaker_off}},
|
mesecons= {effector={rules=pipeworks.rules_all,action_on=node_breaker_on, action_off=node_breaker_off}},
|
||||||
sounds = default.node_sound_stone_defaults(),
|
sounds = default.node_sound_stone_defaults(),
|
||||||
tube = {connect_sides={back=1}},
|
tube = {connect_sides={back=1}},
|
||||||
on_construct = function(pos)
|
on_construct = function(pos)
|
||||||
|
@ -245,7 +245,7 @@ minetest.register_node("pipeworks:nodebreaker_on", {
|
||||||
description = "Node Breaker",
|
description = "Node Breaker",
|
||||||
tile_images = {"pipeworks_nodebreaker_top_on.png","pipeworks_nodebreaker_bottom_on.png","pipeworks_nodebreaker_side2_on.png","pipeworks_nodebreaker_side1_on.png",
|
tile_images = {"pipeworks_nodebreaker_top_on.png","pipeworks_nodebreaker_bottom_on.png","pipeworks_nodebreaker_side2_on.png","pipeworks_nodebreaker_side1_on.png",
|
||||||
"pipeworks_nodebreaker_back.png","pipeworks_nodebreaker_front_on.png"},
|
"pipeworks_nodebreaker_back.png","pipeworks_nodebreaker_front_on.png"},
|
||||||
mesecons= {effector={rules=rules_all,action_on=node_breaker_on, action_off=node_breaker_off}},
|
mesecons= {effector={rules=pipeworks.rules_all,action_on=node_breaker_on, action_off=node_breaker_off}},
|
||||||
is_ground_content = true,
|
is_ground_content = true,
|
||||||
paramtype2 = "facedir",
|
paramtype2 = "facedir",
|
||||||
groups = {snappy=2,choppy=2,oddly_breakable_by_hand=2, mesecon = 2,tubedevice=1,not_in_creative_inventory=1},
|
groups = {snappy=2,choppy=2,oddly_breakable_by_hand=2, mesecon = 2,tubedevice=1,not_in_creative_inventory=1},
|
||||||
|
|
Loading…
Reference in New Issue
Block a user